diff options
author | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2018-11-07 11:14:13 +0300 |
---|---|---|
committer | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2019-01-25 22:36:49 +0300 |
commit | 28bdeb19125a251cdd52927864af2bba37fb9b09 (patch) | |
tree | 0e23fb71933d3f0280e2f7cb953dc0d7337e844d /src/models | |
parent | c10beda805afff7cee86ae9dce964c26fbb3d884 (diff) |
Fix lint errors
Diffstat (limited to 'src/models')
-rw-r--r-- | src/models/task.js | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/models/task.js b/src/models/task.js index ffd3deba..51f02395 100644 --- a/src/models/task.js +++ b/src/models/task.js @@ -32,6 +32,7 @@ export default class Task { * * @param {string} vcalendar the vcalendar data as string with proper new lines * @param {object} calendar the calendar which the task belongs to + * @param {object} raw the raw vcalendar data * @memberof Task */ constructor(vcalendar, calendar, raw) { @@ -141,7 +142,7 @@ export default class Task { */ get summary() { var vtodo = this.vCalendar.getFirstSubcomponent('vtodo') - return vtodo.getFirstPropertyValue('summary'); + return vtodo.getFirstPropertyValue('summary') } /** @@ -176,18 +177,18 @@ export default class Task { /** * Set the categories * - * @param {string} categories the categories + * @param {string} newCategories the categories * @memberof Task */ - set categories(cats) { + set categories(newCategories) { var vtodo = this.vCalendar.getFirstSubcomponent('vtodo') var categories = vtodo.getFirstProperty('categories') - if (cats.length > 0) { + if (newCategories.length > 0) { if (categories) { - categories.setValues(cats) + categories.setValues(newCategories) } else { var prop = new ICAL.Property('categories') - prop.setValues(cats) + prop.setValues(newCategories) categories = vtodo.addProperty(prop) } } else { @@ -197,7 +198,7 @@ export default class Task { this.vcalendar = this.vCalendar.toString() } - updateLastModified () { + updateLastModified() { var vtodo = this.vCalendar.getFirstSubcomponent('vtodo') vtodo.updatePropertyWithValue('last-modified', ICAL.Time.now()) vtodo.updatePropertyWithValue('dtstamp', ICAL.Time.now()) |