NOMDL workshop: fixing correct arguments order after recent Petr's play with property_exists()
This commit is contained in:
@@ -170,7 +170,7 @@ class workshop {
|
||||
*/
|
||||
public function __construct(stdclass $dbrecord, stdclass $cm, stdclass $course, stdclass $context=null) {
|
||||
foreach ($dbrecord as $field => $value) {
|
||||
if (property_exists($field, 'workshop')) {
|
||||
if (property_exists('workshop', $field)) {
|
||||
$this->{$field} = $value;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user