File tree 1 file changed +4
-6
lines changed
1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -230,9 +230,8 @@ export class DateModule {
230
230
*
231
231
* @since 3.0.1
232
232
*/
233
- month ( options ?: { abbr ?: boolean ; context ?: boolean } ) : string {
234
- const abbr = options ?. abbr ?? false ;
235
- const context = options ?. context ?? false ;
233
+ month ( options : { abbr ?: boolean ; context ?: boolean } = { } ) : string {
234
+ const { abbr = false , context = false } = options ;
236
235
237
236
const source = this . faker . definitions . date . month ;
238
237
let type : keyof DateEntryDefinition ;
@@ -266,9 +265,8 @@ export class DateModule {
266
265
*
267
266
* @since 3.0.1
268
267
*/
269
- weekday ( options ?: { abbr ?: boolean ; context ?: boolean } ) : string {
270
- const abbr = options ?. abbr ?? false ;
271
- const context = options ?. context ?? false ;
268
+ weekday ( options : { abbr ?: boolean ; context ?: boolean } = { } ) : string {
269
+ const { abbr = false , context = false } = options ;
272
270
273
271
const source = this . faker . definitions . date . weekday ;
274
272
let type : keyof DateEntryDefinition ;
You can’t perform that action at this time.
0 commit comments