Browse Source

feat(core): Set default DB timezone to UTC

BREAKING CHANGE: The default `dbConnectionOptions.timezone` setting is now set to `'Z'` (UTC). If you have not explicitly set the timezone in your project, then up until now it would have defaulted to `'local'`. To preserve this behavior you can override this new default by setting `dbConnectionOptions.timezone: 'local'` in your VendureConfig.
Michael Bromley 6 years ago
parent
commit
8bf2c7a8c3
1 changed files with 1 additions and 0 deletions
  1. 1 0
      packages/core/src/config/default-config.ts

+ 1 - 0
packages/core/src/config/default-config.ts

@@ -54,6 +54,7 @@ export const defaultConfig: RuntimeVendureConfig = {
         uploadMaxFileSize: 20971520,
         uploadMaxFileSize: 20971520,
     },
     },
     dbConnectionOptions: {
     dbConnectionOptions: {
+        timezone: 'Z',
         type: 'mysql',
         type: 'mysql',
         logger: new TypeOrmLogger(),
         logger: new TypeOrmLogger(),
     },
     },