File tree Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Original file line number Diff line number Diff line change @@ -58,14 +58,6 @@ const MAX_SIZE_TO_COMPILE = 1000;
58
58
59
59
const FULL_CHUNK_HEIGHT = 16 ;
60
60
61
- function allValues ( obj ) {
62
- const values = [ ] ;
63
- for ( const key in obj ) {
64
- values . push ( obj [ key ] ) ;
65
- }
66
- return values ;
67
- }
68
-
69
61
/**
70
62
* Overrides certain methods on a 2d ctx so that when they are called they
71
63
* will also call the same method on the destCtx. The methods that are
@@ -619,7 +611,9 @@ class CanvasExtraStateDependenciesRecorder extends CanvasExtraState {
619
611
}
620
612
621
613
takeDependencies ( ) {
622
- if ( this . _dependencies . size === 0 ) return ;
614
+ if ( this . _dependencies . size === 0 ) {
615
+ return undefined ;
616
+ }
623
617
624
618
const arr = Array . from ( this . _dependencies ) ;
625
619
this . _dependencies . clear ( ) ;
Original file line number Diff line number Diff line change @@ -268,7 +268,9 @@ export class CanvasRecorder {
268
268
// console.warn(`Untracked call to ${name}`);
269
269
this . #unknown( ) ;
270
270
}
271
- if ( deps ) this . #registerDependencies( deps ) ;
271
+ if ( deps ) {
272
+ this . #registerDependencies( deps ) ;
273
+ }
272
274
return this . #ctx[ name ] ( ...args ) ;
273
275
} ;
274
276
}
You can’t perform that action at this time.
0 commit comments