Skip to content

Commit 1826400

Browse files
authored
Add missing JSON.stringify in database:settings:set (#3217)
* Add missing JSON.stringify in database:settings:set
1 parent 20e11f8 commit 1826400

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22
- Add support for reading/writing mfaInfo field in Auth Emulator (#3173).
33
- Work around CORS issues with jsdom in Auth Emulator and Emulator Hub (#3224).
44
- Fixes port conflict issues with `functions:shell` (#3210).
5+
- Fixes issue where `database:settings:set` would cause an error with valid input (#3217).

src/commands/database-settings-set.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export default new Command("database:settings:set <path> <value>")
4343
);
4444
const c = new Client({ urlPrefix: u.origin, auth: true });
4545
try {
46-
await c.put(u.pathname, parsedValue);
46+
await c.put(u.pathname, JSON.stringify(parsedValue));
4747
} catch (err) {
4848
throw new FirebaseError(`Unexpected error fetching configs at ${path}`, {
4949
exit: 2,

0 commit comments

Comments
 (0)