Skip to content

Commit b9f8256

Browse files
chore: fix eslint warning no-unused-vars
Signed-off-by: SebastianKrupinski <krupinskis05@gmail.com>
1 parent 2fae710 commit b9f8256

18 files changed

Lines changed: 29 additions & 37 deletions

eslint.config.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export default [
2020
},
2121
rules: {
2222
// Relax some rules for now. Can be improved later on (baseline).
23-
'@typescript-eslint/no-unused-vars': 'warn',
2423
'vue/multi-word-component-names': 'warn',
2524
'preserve-caught-error': 'warn',
2625
'@nextcloud/no-deprecated-library-props': 'warn',

src/components/AppNavigation/AppNavigationHeader/AppNavigationHeaderDatePicker.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import { isRTL as isRTLFn, t } from '@nextcloud/l10n'
88
import { NcButton, NcDateTimePicker } from '@nextcloud/vue'
99
import { useHotKey } from '@nextcloud/vue/composables/useHotKey'
10-
import { computed, ref } from 'vue'
10+
import { computed } from 'vue'
1111
import { useRoute, useRouter } from 'vue-router'
1212
import ChevronLeftIcon from 'vue-material-design-icons/ChevronLeft.vue'
1313
import ChevronRightIcon from 'vue-material-design-icons/ChevronRight.vue'

src/components/AppNavigation/CalendarList/Trashbin.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export default {
171171
let eventSummary = t('calendar', 'Untitled item')
172172
try {
173173
eventSummary = vobject?.calendarComponent.getComponentIterator().next().value?.title
174-
} catch (e) {
174+
} catch {
175175
// ignore
176176
}
177177
let subline = vobject.calendar?.displayName || t('calendar', 'Unknown calendar')

src/components/AppNavigation/EditCalendarModal.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,7 @@ export default {
467467
if (this.isAfterVersion && this.defaultAlarmChanged) {
468468
await this.saveDefaultAlarm()
469469
}
470-
} catch (error) {
470+
} catch {
471471
showError(this.$t('calendar', 'Failed to save calendar name and color'))
472472
}
473473

src/components/AppNavigation/EditCalendarModal/SharingSearch.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ export default {
192192
let results
193193
try {
194194
results = await principalPropertySearchByDisplaynameOrEmail(query)
195-
} catch (error) {
195+
} catch {
196196
return []
197197
}
198198
@@ -252,7 +252,7 @@ export default {
252252
itemType: 'principals',
253253
},
254254
})
255-
} catch (error) {
255+
} catch {
256256
return []
257257
}
258258
@@ -309,7 +309,7 @@ export default {
309309
lookup: false,
310310
},
311311
})
312-
} catch (error) {
312+
} catch {
313313
return []
314314
}
315315

src/components/AppNavigation/Proposal/ProposalList.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,15 +222,15 @@ export default {
222222
await this.proposalStore.destroyProposal(proposal)
223223
showSuccess(t('calendar', 'Successfully deleted proposal'))
224224
this.fetchProposals()
225-
} catch (error) {
225+
} catch {
226226
showError(t('calendar', 'Failed to delete proposal'))
227227
}
228228
},
229229
230230
async fetchProposals() {
231231
try {
232232
this.storedProposals = await this.proposalStore.listProposals()
233-
} catch (error) {
233+
} catch {
234234
showError(t('calendar', 'Failed to retrieve proposals'))
235235
}
236236
},

src/components/AppNavigation/Settings.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,6 @@ import {
183183
IMPORT_STAGE_IMPORTING,
184184
IMPORT_STAGE_PROCESSING,
185185
} from '../../models/consts.js'
186-
import { getCurrentUserPrincipal } from '../../services/caldavService.js'
187186
import useCalendarsStore from '../../store/calendars.js'
188187
import useImportFilesStore from '../../store/importFiles.js'
189188
import usePrincipalsStore from '../../store/principals.js'

src/components/Editor/AvatarParticipationStatus.vue

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ export default {
170170
}
171171
case 'DELEGATED':
172172
return {
173-
icon: IconDelegated,
173+
...delegatedIcon,
174174
text: t('calendar', 'Invitation is delegated'),
175175
}
176176
case 'DECLINED':
@@ -203,13 +203,13 @@ export default {
203203
if (!this.scheduleStatus || this.scheduleStatus === '1.0') {
204204
if (this.isResource) {
205205
return {
206-
icon: IconNoResponse,
206+
...noResponseIcon,
207207
text: t('calendar', 'Will be booked after saving, if available'),
208208
}
209209
}
210210
211211
return {
212-
icon: IconNoResponse,
212+
...noResponseIcon,
213213
text: t('calendar', 'Invitation will be sent'),
214214
}
215215
}
@@ -219,32 +219,32 @@ export default {
219219
if (this.scheduleStatus[0] === '3' || this.scheduleStatus[0] === '5') {
220220
if (this.isResource) {
221221
return {
222-
icon: IconNoResponse,
222+
...noResponseIcon,
223223
text: t('calendar', 'Failed to check availability'),
224224
}
225225
}
226226
227227
return {
228-
icon: IconNoResponse,
228+
...noResponseIcon,
229229
text: t('calendar', 'Failed to deliver invitation'),
230230
}
231231
}
232232
233233
return {
234-
icon: IconNoResponse,
234+
...noResponseIcon,
235235
text: t('calendar', 'Awaiting response'),
236236
}
237237
}
238238
239239
if (this.isResource) {
240240
return {
241-
icon: IconNoResponse,
241+
...noResponseIcon,
242242
text: t('calendar', 'Checking availability'),
243243
}
244244
}
245245
246246
return {
247-
icon: IconNoResponse,
247+
...noResponseIcon,
248248
text: t('calendar', 'Has not responded to {organizerName}\'s invitation yet', {
249249
organizerName: this.organizerDisplayName,
250250
}),

src/components/Editor/InvitationResponseButtons.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ export default {
117117
await this.setParticipationStatus('ACCEPTED')
118118
showSuccess(this.t('calendar', 'The invitation has been accepted successfully.'))
119119
this.$emit('close')
120-
} catch (e) {
120+
} catch {
121121
showError(this.t('calendar', 'Failed to accept the invitation.'))
122122
}
123123
},
@@ -127,7 +127,7 @@ export default {
127127
await this.setParticipationStatus('DECLINED')
128128
showSuccess(this.t('calendar', 'The invitation has been declined successfully.'))
129129
this.$emit('close')
130-
} catch (e) {
130+
} catch {
131131
showError(this.t('calendar', 'Failed to decline the invitation.'))
132132
}
133133
},
@@ -137,7 +137,7 @@ export default {
137137
await this.setParticipationStatus('TENTATIVE')
138138
showSuccess(this.t('calendar', 'Your participation has been marked as tentative.'))
139139
this.$emit('close')
140-
} catch (e) {
140+
} catch {
141141
showError(this.t('calendar', 'Failed to set the participation status to tentative.'))
142142
}
143143
},

src/components/Editor/Invitees/AttendeeDisplay.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ export default {
8181
const text = `${this.displayName} <${this.email}>`
8282
await navigator.clipboard.writeText(text)
8383
showSuccess(this.$t('calendar', 'Copied to clipboard'))
84-
} catch (e) {
84+
} catch {
8585
showError(this.$t('calendar', 'Failed to copy'))
8686
}
8787
},

0 commit comments

Comments
 (0)