about summary refs log tree commit diff stats
path: root/src/utils
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/twtstr.nim7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim
index c7ba2db6..f735252c 100644
--- a/src/utils/twtstr.nim
+++ b/src/utils/twtstr.nim
@@ -8,10 +8,11 @@ import options
 import punycode
 
 import bindings/libunicode
-import data/idna
 import data/charwidth
-import utils/opt
+import data/idna
+import js/javascript
 import utils/map
+import utils/opt
 
 when defined(posix):
   import posix
@@ -1074,7 +1075,7 @@ func twidth*(s: string, w: int): int =
 func breaksWord*(r: Rune): bool =
   return not (r.isDigitAscii() or r.width() == 0 or r.isAlpha())
 
-type BoundaryFunction* = proc(x: Rune): Opt[bool]
+type BoundaryFunction* = proc(x: Rune): Result[bool, JSError]
 
 proc breaksWord*(r: Rune, check: Opt[BoundaryFunction]): bool =
   if check.isSome: