ReferenceError'ised two more JS throw statements
This commit is contained in:
@@ -99,7 +99,7 @@ function shot_open(shot_id) {
|
||||
*/
|
||||
function task_create(shot_id, project_url, task_type) {
|
||||
if (shot_id === undefined || project_url === undefined || task_type === undefined) {
|
||||
throw "task_create(" + shot_id + ", " + project_url+ ", " + task_type + ") called.";
|
||||
throw new ReferenceError("task_create(" + shot_id + ", " + project_url+ ", " + task_type + ") called.");
|
||||
}
|
||||
var url = '/attract/' + project_url + '/tasks/create';
|
||||
|
||||
@@ -125,7 +125,7 @@ function attract_form_save(form_id, item_id, item_save_url, options={})
|
||||
{
|
||||
// Mandatory option.
|
||||
if (typeof options.type === 'undefined') {
|
||||
throw 'attract_form_save(): options.type is mandatory.';
|
||||
throw new ReferenceError('attract_form_save(): options.type is mandatory.');
|
||||
}
|
||||
|
||||
var $form = $('#' + form_id);
|
||||
|
Reference in New Issue
Block a user