From d1b27878094175b2affa7cf94037c5f60b3b1bbc Mon Sep 17 00:00:00 2001 From: Aria Minaei Date: Sat, 3 Jul 2021 15:40:58 +0200 Subject: [PATCH] Fix: Fixed the regression from last commit --- .../core/src/sheetObjects/SheetObjectTemplate.test.ts | 11 +++++------ .../src/sheetObjects/getPropDefaultsOfSheetObject.ts | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/theatre/core/src/sheetObjects/SheetObjectTemplate.test.ts b/theatre/core/src/sheetObjects/SheetObjectTemplate.test.ts index 663d2fd..091c0d4 100644 --- a/theatre/core/src/sheetObjects/SheetObjectTemplate.test.ts +++ b/theatre/core/src/sheetObjects/SheetObjectTemplate.test.ts @@ -22,9 +22,8 @@ describe(`SheetObjectTemplate`, () => { obj: { trackIdByPropPath: { [encodePathToProp(['position', 'x'])]: asSequenceTrackId('x'), - [encodePathToProp(['position', 'invalid'])]: asSequenceTrackId( - 'invalidTrack', - ), + [encodePathToProp(['position', 'invalid'])]: + asSequenceTrackId('invalidTrack'), }, trackData: { x: null as $IntentionalAny, @@ -78,9 +77,8 @@ describe(`SheetObjectTemplate`, () => { obj: { trackIdByPropPath: { [encodePathToProp(['position', 'x'])]: asSequenceTrackId('x'), - [encodePathToProp(['position', 'invalid'])]: asSequenceTrackId( - 'invalidTrack', - ), + [encodePathToProp(['position', 'invalid'])]: + asSequenceTrackId('invalidTrack'), }, trackData: { x: null as $IntentionalAny, @@ -91,6 +89,7 @@ describe(`SheetObjectTemplate`, () => { }, }) + debugger const iter = iterateOver( obj.template.getMapOfValidSequenceTracks_forStudio(), ) diff --git a/theatre/core/src/sheetObjects/getPropDefaultsOfSheetObject.ts b/theatre/core/src/sheetObjects/getPropDefaultsOfSheetObject.ts index 3b7163b..10ac177 100644 --- a/theatre/core/src/sheetObjects/getPropDefaultsOfSheetObject.ts +++ b/theatre/core/src/sheetObjects/getPropDefaultsOfSheetObject.ts @@ -19,7 +19,7 @@ const cachedDefaults = new WeakMap() export default function getPropDefaultsOfSheetObject( config: SheetObjectConfig<$IntentionalAny>, ): SerializableMap { - return getDefaultsOfPropTypeConfig(config.props) as $IntentionalAny + return getDefaultsOfPropTypeConfig(config) as $IntentionalAny } function getDefaultsOfPropTypeConfig(