import type { Assert } from './prelude.js' import rethrow from './rethrow.js' const nullOr: (a: Assert) => Assert = a => value => value === null ? null : rethrow(a, 'Was not null.')(value) export default nullOr