diff --git a/package.json b/package.json index d9508d3..e34d1ec 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "@hibas123/realtime-db", + "name": "@hibas123/realtimedb", "version": "1.0.0", "description": "", "main": "lib/index.js", @@ -40,4 +40,4 @@ "shortid": "^2.2.15", "socket.io": "^2.2.0" } -} +} \ No newline at end of file diff --git a/src/database/rules.ts b/src/database/rules.ts index c875530..4d7178c 100644 --- a/src/database/rules.ts +++ b/src/database/rules.ts @@ -64,7 +64,7 @@ export class Rules { let rules = this.rules; for (let segment of path) { - rules = rules[segment]; + rules = rules[segment] || rules["*"]; if (rules) { if (rules[".read"]) { read = rules[".read"]