Skip to content

Commit

Permalink
fix empty tableconfig bug
Browse files Browse the repository at this point in the history
  • Loading branch information
prostgles committed Oct 27, 2023
1 parent a481c37 commit a22dc10
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions lib/TableConfig/TableConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ export default class TableConfigurator<LANG_IDS = { en: 1 }> {

instanceId = Math.random();

config?: TableConfig<LANG_IDS>;
config: TableConfig<LANG_IDS> = {};
get dbo(): DBHandlerServer {
if (!this.prostgles.dbo) throw "this.prostgles.dbo missing"
return this.prostgles.dbo
Expand Down Expand Up @@ -475,8 +475,8 @@ export default class TableConfigurator<LANG_IDS = { en: 1 }> {
return 1;
}

if (!this.config || !this.prostgles.pgp){
throw "config or pgp missing";
if (!this.prostgles.pgp){
throw "pgp missing";
}

const MAX_IDENTIFIER_LENGTH = +(await this.db.one("SHOW max_identifier_length;") as any).max_identifier_length;
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "prostgles-server",
"version": "4.1.99",
"version": "4.1.100",
"description": "",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion tests/client/PID.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1097907
1100681
2 changes: 1 addition & 1 deletion tests/server/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a22dc10

Please sign in to comment.