Fixed JS issue. JS doesn't support default function arguments.
This commit is contained in:
@@ -173,10 +173,10 @@ function task_create(shot_id, project_url, task_type)
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function attract_form_save(form_id, item_id, item_save_url, options={})
|
function attract_form_save(form_id, item_id, item_save_url, options)
|
||||||
{
|
{
|
||||||
// Mandatory option.
|
// Mandatory option.
|
||||||
if (typeof options.type === 'undefined') {
|
if (typeof options === 'undefined' || typeof options.type === 'undefined') {
|
||||||
throw new ReferenceError('attract_form_save(): options.type is mandatory.');
|
throw new ReferenceError('attract_form_save(): options.type is mandatory.');
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -332,4 +332,3 @@ $(function() {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user