Skip to content

Commit b896bbf

Browse files
committed
Merge branch 'fix/deno_2_test_and_build' of github.com:bids-standard/bids-validator-temp into fix/deno_2_test_and_build
2 parents e36d8f5 + 6d85c62 commit b896bbf

File tree

6 files changed

+2
-272
lines changed

6 files changed

+2
-272
lines changed

.circleci/config.yml

Lines changed: 0 additions & 84 deletions
This file was deleted.

.github/workflows/docker-build-push.yml

Lines changed: 0 additions & 38 deletions
This file was deleted.

.github/workflows/node_tests.yml

Lines changed: 0 additions & 60 deletions
This file was deleted.

.github/workflows/test-bids-examples.yml

Lines changed: 0 additions & 77 deletions
This file was deleted.

bids-validator/deno.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"@hed/validator": "npm:[email protected]",
3636
"@ignore": "npm:[email protected]",
3737
"@libs/xml": "jsr:@libs/[email protected]",
38-
"@mango/nifti": "npm:[email protected].8",
38+
"@mango/nifti": "npm:@bids/[email protected].9",
3939
"@std/assert": "jsr:@std/[email protected]",
4040
"@std/fmt": "jsr:@std/[email protected]",
4141
"@std/fs": "jsr:@std/[email protected]",

bids-validator/src/files/nifti.ts

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,11 @@ async function extract(buffer: Uint8Array, nbytes: number): Promise<Uint8Array>
2727
return result
2828
}
2929

30-
function readHeaderQuiet(buf: ArrayBuffer) {
31-
const console_error = console.error
32-
const console_log = console.log
33-
console.error = (msg: string) => { logger.info(msg)}
34-
console.log = (msg: string) => { logger.info(msg)}
35-
const header = readHeader(buf)
36-
console.error = console_error
37-
console.log = console_log
38-
return header
39-
}
40-
4130
export async function loadHeader(file: BIDSFile): Promise<NiftiHeader> {
4231
try {
4332
const buf = await file.readBytes(1024)
4433
const data = isCompressed(buf.buffer) ? await extract(buf, 540) : buf
45-
const header = readHeaderQuiet(data.buffer)
34+
const header = readHeader(data.buffer)
4635
if (!header) {
4736
throw { key: 'NIFTI_HEADER_UNREADABLE' }
4837
}

0 commit comments

Comments
 (0)