1
Fork 0

typescript(option): fix: Fixed the name of isNone

typescript(option):
typescript(option): Previously the name was isNothing bu isNone makes more sense
typescript(option):
typescript(option): BREAKING CHANGE: Changed the name of isNothing to isNone

Signed-off-by: prescientmoon <git@moonythm.dev>
This commit is contained in:
Matei Adriel 2019-12-23 14:16:32 +02:00 committed by prescientmoon
parent d02031e416
commit f46ef3dbf8
Signed by: prescientmoon
SSH key fingerprint: SHA256:UUF9JT2s8Xfyv76b8ZuVL7XrmimH4o49p4b+iexbVH4
2 changed files with 3 additions and 3 deletions

View file

@ -1,4 +1,4 @@
import { Option } from '../types'
import { none } from '../internals'
export const isNothing = <T>(option: Option<T>) => option.__brand === none
export const isNone = <T>(option: Option<T>) => option.__brand === none

View file

@ -1,4 +1,4 @@
import { Option } from '../types'
import { isNothing } from './isNone'
import { isNone } from './isNone'
export const isSome = <T>(option: Option<T>) => !isNothing(option)
export const isSome = <T>(option: Option<T>) => !isNone(option)