File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -27,20 +27,20 @@ export interface CopyOnWriteOptions {
2727 journal ?: Journal ;
2828}
2929
30- const journalOperations = [ 'delete' ] as const ;
30+ const journalOperations = new Set ( [ 'delete' ] ) ;
3131
3232/**
3333 * @category Internals
3434 * @internal
3535 */
36- export type JournalOperation = ( typeof journalOperations ) [ number ] ;
36+ export type JournalOperation = 'delete' ;
3737
3838/** Because TS doesn't work right w/o it */
3939function isJournalOp ( op : string ) : op is JournalOperation {
40- return journalOperations . some ( operation => operation === op ) ;
40+ return journalOperations . has ( op ) ;
4141}
4242
43- const maxOpLength = Math . max ( ...journalOperations . map ( op => op . length ) ) ;
43+ const maxOpLength = Math . max ( ...journalOperations . values ( ) . map ( op => op . length ) ) ;
4444
4545/**
4646 * @category Internals
You can’t perform that action at this time.
0 commit comments