Skip to content

Commit

Permalink
Merge pull request #545 from nextcloud/fix/jsdoc/boolean-casing
Browse files Browse the repository at this point in the history
fix(jsdoc): Fix casing of boolean types
  • Loading branch information
ChristophWurst authored Dec 28, 2022
2 parents 655621f + ac1a9b6 commit 050ea3f
Show file tree
Hide file tree
Showing 17 changed files with 40 additions and 40 deletions.
8 changes: 4 additions & 4 deletions src/components/abstractComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@ export default class AbstractComponent extends observerTrait(lockableTrait(class
* Adds a new component to this component
*
* @param {AbstractComponent} component The component to add
* @return {Boolean}
* @return {boolean}
*/
addComponent(component) {
this._modify()
Expand Down Expand Up @@ -592,7 +592,7 @@ export default class AbstractComponent extends observerTrait(lockableTrait(class
*
* @param {Object} prototype The object's prototype
* @param {Object} options The options for advertising properties
* @param {Boolean} advertiseValueOnly Whether to advertise the value only or the entire property
* @param {boolean} advertiseValueOnly Whether to advertise the value only or the entire property
*/
export function advertiseSingleOccurrenceProperty(prototype, options, advertiseValueOnly = true) {
options = getDefaultOncePropConfig(options)
Expand Down Expand Up @@ -776,7 +776,7 @@ function getDefaultOncePropConfig(options) {
* @param {Object|String} options The options object
* @param {String} options.name Advertised name of property
* @param {String=} options.iCalendarName The iCalendar name of the property
* @param {Boolean=} options.customAddMethod Whether or not to use a custom add method
* @param {boolean=} options.customAddMethod Whether or not to use a custom add method
* @return {Object}
*/
function getDefaultMultiplePropConfig(options) {
Expand All @@ -798,7 +798,7 @@ function getDefaultMultiplePropConfig(options) {
* @param {Object|String} options Options destructuring object
* @param {String} options.name Advertised name of component
* @param {String=} options.iCalendarName The iCalendar name of the component
* @param {Boolean=} options.customAddMethod Whether or not to use a custom add method
* @param {boolean=} options.customAddMethod Whether or not to use a custom add method
* @return {Object}
*/
function getDefaultMultipleCompConfig(options) {
Expand Down
2 changes: 1 addition & 1 deletion src/components/nested/alarmComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export default class AlarmComponent extends AbstractComponent {
* Sets a relative trigger
*
* @param {DurationValue} alarmOffset - Relative time of the trigger, either related to start or end
* @param {Boolean=} relatedToStart - Related to Start or end?
* @param {boolean=} relatedToStart - Related to Start or end?
*/
setTriggerFromRelative(alarmOffset, relatedToStart = true) {
const triggerProperty = TriggerProperty.fromRelativeAndRelated(alarmOffset, relatedToStart)
Expand Down
8 changes: 4 additions & 4 deletions src/components/root/abstractRecurringComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -538,9 +538,9 @@ export default class AbstractRecurringComponent extends AbstractComponent {
* If the parameter thisAndAllFuture is set to true,
* it will remove this and all future occurrences
*
* @param {Boolean} thisAndAllFuture Whether to create an exception for this and all future
* @param {boolean} thisAndAllFuture Whether to create an exception for this and all future
* @throws EmptyRecurrenceSetError Thrown, when deleting an occurrence results in no more events
* @return {Boolean} true if this deleted the last occurrence in set, false if there are occurrences left
* @return {boolean} true if this deleted the last occurrence in set, false if there are occurrences left
*/
removeThisOccurrence(thisAndAllFuture = false) {
if (!this.isPartOfRecurrenceSet()) {
Expand Down Expand Up @@ -653,7 +653,7 @@ export default class AbstractRecurringComponent extends AbstractComponent {
* @param {String} email The email-address of the attendee to add
* @param {String} role The role of the attendee to add
* @param {String} userType The type of attendee to add
* @param {Boolean} rsvp Whether or not to request a response from the attendee
* @param {boolean} rsvp Whether or not to request a response from the attendee
* @return {boolean}
*/
addAttendeeFromNameEMailRoleUserTypeAndRSVP(name, email, role, userType, rsvp) {
Expand Down Expand Up @@ -780,7 +780,7 @@ export default class AbstractRecurringComponent extends AbstractComponent {
*
* @param {String} action The type of alarm Action
* @param {DurationValue} alarmOffset The trigger time of the alarm
* @param {Boolean=} relatedToStart Whether or not the alarm is related to the event's start
* @param {boolean=} relatedToStart Whether or not the alarm is related to the event's start
* @return {AlarmComponent}
*/
addRelativeAlarm(action, alarmOffset, relatedToStart = true) {
Expand Down
2 changes: 1 addition & 1 deletion src/components/root/eventComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ export default class EventComponent extends AbstractRecurringComponent {
* Shifts the entire event by the given duration
*
* @param {DurationValue} delta The duration to shift event by
* @param {Boolean} allDay Whether the updated event should be all-day or not
* @param {boolean} allDay Whether the updated event should be all-day or not
* @param {Timezone} defaultTimezone The default timezone if moving from all-day to timed event
* @param {DurationValue} defaultAllDayDuration The default all-day duration if moving from timed to all-day
* @param {DurationValue} defaultTimedDuration The default timed duration if moving from all-day to timed
Expand Down
2 changes: 1 addition & 1 deletion src/components/root/toDoComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ export default class ToDoComponent extends AbstractRecurringComponent {
* Shifts the entire task by the given duration
*
* @param {DurationValue} delta The duration to shift event by
* @param {Boolean} allDay Whether the updated event should be all-day or not
* @param {boolean} allDay Whether the updated event should be all-day or not
* @param {Timezone} defaultTimezone The default timezone if moving from all-day to timed event
* @param {DurationValue} defaultAllDayDuration The default all-day duration if moving from timed to all-day
* @param {DurationValue} defaultTimedDuration The default timed duration if moving from all-day to timed
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/stringHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export function lc(str) {
*
* @param {String} str1 String 1 to compare
* @param {String} str2 String 2 to compare
* @return {Boolean}
* @return {boolean}
*/
export function strcasecmp(str1, str2) {
return uc(str1) === uc(str2)
Expand Down
2 changes: 1 addition & 1 deletion src/parameters/parameter.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export default class Parameter extends observerTrait(lockableTrait(class {})) {
/**
* Returns whether or not the value is a multivalue
*
* @return {Boolean}
* @return {boolean}
*/
isMultiValue() {
return Array.isArray(this._value)
Expand Down
12 changes: 6 additions & 6 deletions src/parsers/abstractParser.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ export default class AbstractParser {
* @constructor
*
* @param {Object=} options Object of options
* @param {Boolean=} options.extractGlobalProperties Whether or not to preserve properties from the VCALENDAR component (defaults to false)
* @param {Boolean=} options.removeRSVPForAttendees Whether or not to remove RSVP from attendees (defaults to false)
* @param {Boolean=} options.includeTimezones Whether or not to include timezones (defaults to false)
* @param {Boolean=} options.preserveMethod Whether or not to preserve the iCalendar method (defaults to false)
* @param {Boolean=} options.processFreeBusy Whether or not to process VFreeBusy components (defaults to false)
* @param {boolean=} options.extractGlobalProperties Whether or not to preserve properties from the VCALENDAR component (defaults to false)
* @param {boolean=} options.removeRSVPForAttendees Whether or not to remove RSVP from attendees (defaults to false)
* @param {boolean=} options.includeTimezones Whether or not to include timezones (defaults to false)
* @param {boolean=} options.preserveMethod Whether or not to preserve the iCalendar method (defaults to false)
* @param {boolean=} options.processFreeBusy Whether or not to process VFreeBusy components (defaults to false)
*/
constructor(options = {}) {
if (new.target === AbstractParser) {
Expand All @@ -44,7 +44,7 @@ export default class AbstractParser {
/**
* Options for the parser
*
* @type {{removeRSVPForAttendees: Boolean}}
* @type {{removeRSVPForAttendees: boolean}}
* @private
*/
this._options = Object.assign({}, options)
Expand Down
10 changes: 5 additions & 5 deletions src/parsers/parserManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ export default class ParserManager {
*
* @param {String} fileType The mime-type to get a parser for
* @param {Object=} options Options destructuring object
* @param {Boolean=} options.extractGlobalProperties Whether or not to preserve properties from the VCALENDAR component (defaults to false)
* @param {Boolean=} options.removeRSVPForAttendees Whether or not to remove RSVP from attendees (defaults to false)
* @param {Boolean=} options.includeTimezones Whether or not to include timezones (defaults to false)
* @param {Boolean=} options.preserveMethod Whether or not to preserve the iCalendar method (defaults to false)
* @param {Boolean=} options.processFreeBusy Whether or not to process VFreeBusy components (defaults to false)
* @param {boolean=} options.extractGlobalProperties Whether or not to preserve properties from the VCALENDAR component (defaults to false)
* @param {boolean=} options.removeRSVPForAttendees Whether or not to remove RSVP from attendees (defaults to false)
* @param {boolean=} options.includeTimezones Whether or not to include timezones (defaults to false)
* @param {boolean=} options.preserveMethod Whether or not to preserve the iCalendar method (defaults to false)
* @param {boolean=} options.processFreeBusy Whether or not to process VFreeBusy components (defaults to false)
*
* @return {AbstractParser}
*/
Expand Down
6 changes: 3 additions & 3 deletions src/properties/attendeeProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ export default class AttendeeProperty extends Property {
*
* @param {String} name The display name
* @param {String} email The email address
* @param {Boolean=} isOrganizer Whether this is the organizer or an attendee
* @param {boolean=} isOrganizer Whether this is the organizer or an attendee
* @return {AttendeeProperty}
*/
static fromNameAndEMail(name, email, isOrganizer = false) {
Expand All @@ -240,8 +240,8 @@ export default class AttendeeProperty extends Property {
* @param {String} email The email address
* @param {String} role The role
* @param {String} userType The type of user
* @param {Boolean} rsvp Whether to send out an invitation
* @param {Boolean=} isOrganizer Whether this is the organizer or an attendee
* @param {boolean} rsvp Whether to send out an invitation
* @param {boolean=} isOrganizer Whether this is the organizer or an attendee
* @return {AttendeeProperty}
*/
static fromNameEMailRoleUserTypeAndRSVP(name, email, role, userType, rsvp, isOrganizer = false) {
Expand Down
4 changes: 2 additions & 2 deletions src/properties/property.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ export default class Property extends observerTrait(lockableTrait(class {})) {
* Checks if a value is inside this multi-value property
*
* @param {String|AbstractValue} value Value to check for
* @return {Boolean}
* @return {boolean}
*/
hasValue(value) {
if (!this.isMultiValue()) {
Expand Down Expand Up @@ -332,7 +332,7 @@ export default class Property extends observerTrait(lockableTrait(class {})) {
/**
* Returns whether or not the value is a multivalue
*
* @return {Boolean}
* @return {boolean}
*/
isMultiValue() {
return Array.isArray(this._value)
Expand Down
2 changes: 1 addition & 1 deletion src/properties/triggerProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export default class TriggerProperty extends Property {
* Creates a new relative trigger
*
* @param {DurationValue} alarmOffset Duration to create Trigger from
* @param {Boolean=} relatedToStart Related to Start or end?
* @param {boolean=} relatedToStart Related to Start or end?
* @return {TriggerProperty}
*/
static fromRelativeAndRelated(alarmOffset, relatedToStart = true) {
Expand Down
4 changes: 2 additions & 2 deletions src/recurrence/recurrenceManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ export default class RecurrenceManager {
/**
* Checks if a recurrenceID is an RDATE or EXDATE
*
* @param {Boolean} isNegative Whether we are dealing with an EXDATE or RDATE
* @param {boolean} isNegative Whether we are dealing with an EXDATE or RDATE
* @param {DateTimeValue} recurrenceId Recurrence-Id to check
* @return {boolean}
*/
Expand All @@ -428,7 +428,7 @@ export default class RecurrenceManager {

/**
*
* @param {Boolean} isNegative Whether we are dealing with an EXDATE or RDATE
* @param {boolean} isNegative Whether we are dealing with an EXDATE or RDATE
* @param {DateTimeValue} recurrenceId Recurrence-Id to get
* @return {null|DateTimeValue|PeriodValue}
*/
Expand Down
2 changes: 1 addition & 1 deletion src/timezones/timezoneManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export class TimezoneManager {
/**
* Lists all timezones
*
* @param {Boolean=} includeAliases Whether or not to include aliases
* @param {boolean=} includeAliases Whether or not to include aliases
* @return {String[]}
*/
listAllTimezones(includeAliases = false) {
Expand Down
4 changes: 2 additions & 2 deletions src/values/dateTimeValue.js
Original file line number Diff line number Diff line change
Expand Up @@ -419,7 +419,7 @@ export default class DateTimeValue extends AbstractValue {
* Creates a new DateTimeValue object based on a vanilla javascript object
*
* @param {Date} jsDate The JavaScript date to initialise from
* @param {Boolean=} useUTC Whether or not to treat it as UTC
* @param {boolean=} useUTC Whether or not to treat it as UTC
* @return {DateTimeValue}
*/
static fromJSDate(jsDate, useUTC = false) {
Expand All @@ -437,7 +437,7 @@ export default class DateTimeValue extends AbstractValue {
* @param {Number=} data.hour Amount of hours to set
* @param {Number=} data.minute Amount of minutes to set
* @param {Number=} data.second Amount of seconds to set
* @param {Boolean=} data.isDate Whether this is a date or date-time
* @param {boolean=} data.isDate Whether this is a date or date-time
* @param {Timezone=} timezone The timezone of the DateTimeValue
* @return {DateTimeValue}
*/
Expand Down
6 changes: 3 additions & 3 deletions src/values/durationValue.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ export default class DurationValue extends AbstractValue {
/**
* Gets the negative-indicator of the stored duration-value
*
* @return {Boolean}
* @return {boolean}
*/
get isNegative() {
return this._innerValue.isNegative
Expand All @@ -169,7 +169,7 @@ export default class DurationValue extends AbstractValue {
* Gets the negative-indicator of the stored duration-value
*
* @throws {ModificationNotAllowedError} if value is locked for modification
* @param {Boolean} isNegative Whether or not the duration is negative
* @param {boolean} isNegative Whether or not the duration is negative
*/
set isNegative(isNegative) {
this._modifyContent()
Expand Down Expand Up @@ -270,7 +270,7 @@ export default class DurationValue extends AbstractValue {
* @param {Number=} data.hours Number of hours to set
* @param {Number=} data.minutes Number of minutes to set
* @param {Number=} data.seconds Number of seconds to set
* @param {Boolean=} data.isNegative Whether or not duration is negative
* @param {boolean=} data.isNegative Whether or not duration is negative
* @return {DurationValue}
*/
static fromData(data) {
Expand Down
4 changes: 2 additions & 2 deletions src/values/recurValue.js
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ export default class RecurValue extends AbstractValue {
/**
* Checks whether the stored rule is finite
*
* @return {Boolean}
* @return {boolean}
*/
isFinite() {
return this._innerValue.isFinite()
Expand All @@ -210,7 +210,7 @@ export default class RecurValue extends AbstractValue {
/**
* Checks whether the recurrence rule is limited by count
*
* @return {Boolean}
* @return {boolean}
*/
isByCount() {
return this._innerValue.isByCount()
Expand Down

0 comments on commit 050ea3f

Please sign in to comment.