@magic/types
Version:
typechecking library
19 lines (13 loc) • 312 B
JavaScript
import is from '../lib.mjs'
import equal from './equal.mjs'
export const different = (a, b) => {
if (is.undefined(b)) {
if (is.undefined(a)) {
// this most likely is an argument error.
return false
}
return c => different(a, c)
}
return !equal(a, b)
}
export default different