Skip to content

Commit

Permalink
fix: remove ts-expect-error
Browse files Browse the repository at this point in the history
  • Loading branch information
dpilch committed Jul 15, 2024
1 parent f860791 commit 6668967
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions packages/backend-data/src/convert_schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,15 +140,10 @@ export const convertSchemaToCDK = (
}

if (importedTableName) {
return AmplifyDataDefinition.fromString(
schema,
// TODO: remove ignore
{
...IMPORTED_DYNAMO_DATA_SOURCE_STRATEGY,
// @ts-expect-error requires new release of data construct
tableName: importedTableName,
}
);
return AmplifyDataDefinition.fromString(schema, {
...IMPORTED_DYNAMO_DATA_SOURCE_STRATEGY,
tableName: importedTableName,
});
}
return AmplifyDataDefinition.fromString(schema, DYNAMO_DATA_SOURCE_STRATEGY);
};
Expand Down Expand Up @@ -178,10 +173,8 @@ const convertDatabaseConfigurationToDataSourceStrategy = (
): ModelDataSourceStrategy => {
if (configuration.engine === 'dynamodb') {
if (importedTableName) {
// TODO: remove ignore
return {
...IMPORTED_DYNAMO_DATA_SOURCE_STRATEGY,
// @ts-expect-error requires new release of data construct
tableName: importedTableName,
};
}
Expand Down

0 comments on commit 6668967

Please sign in to comment.