Skip to content

Commit d88b6c0

Browse files
committed
revert
1 parent 6130b88 commit d88b6c0

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/).
88

99
### [3.0.0-alpha.10] - 2026-03-25
1010

11-
- convert .yaml to .toml
11+
- config: replace .yaml with .toml
1212
- zone_record can be empty, default 0
1313
- feat(zone records): create and delete
1414

lib/config.test.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,30 +13,35 @@ describe('config', () => {
1313

1414
it(`loads mysql config synchronously`, () => {
1515
const cfg = Config.getSync('mysql')
16+
delete cfg.password
1617
assert.deepEqual(cfg, mysqlCfg)
1718
})
1819

1920
it(`loads mysql config (from cache)`, async () => {
2021
process.env.NODE_DEBUG = 1
2122
const cfg = await Config.get('mysql')
23+
delete cfg.password
2224
assert.deepEqual(cfg, mysqlCfg)
2325
process.env.NODE_DEBUG = ''
2426
})
2527

2628
it(`loads http config`, async () => {
2729
const cfg = await Config.get('http')
2830
const { tls, ...rest } = cfg
31+
delete rest.password
2932
assert.deepEqual(rest, httpCfg)
3033
})
3134

3235
it(`loads http config synchronously`, () => {
3336
const cfg = Config.getSync('http')
3437
const { tls, ...rest } = cfg
38+
delete rest.password
3539
assert.deepEqual(rest, httpCfg)
3640
})
3741

3842
it(`loads tls from conf.d/*.pem when present`, async () => {
3943
const cfg = await Config.get('http')
44+
delete cfg.password
4045
if (!cfg.tls) return // no PEM on this host — skip
4146
assert.match(cfg.tls.key, /-----BEGIN.*PRIVATE KEY-----/)
4247
assert.match(cfg.tls.cert, /-----BEGIN CERTIFICATE-----/)
@@ -81,5 +86,6 @@ const httpCfg = {
8186
isSameSite: 'Strict',
8287
isSecure: true,
8388
isHttpOnly: false,
89+
password: '',
8490
},
8591
}

routes/zone_record.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import validate from '@nictool/validate'
2-
import Joi from 'joi'
32

43
import ZoneRecord from '../lib/zone_record.js'
54
import Zone from '../lib/zone.js'
@@ -97,9 +96,7 @@ function ZoneRecordRoutes(server) {
9796
path: '/zone_record/{id}',
9897
options: {
9998
validate: {
100-
query: Joi.object({
101-
deleted: Joi.boolean(),
102-
}),
99+
query: validate.zone_record.DELETE,
103100
},
104101
response: {
105102
schema: validate.zone_record.GET_res,

0 commit comments

Comments
 (0)