File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed
Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -31,13 +31,11 @@ KeyObject = {
3131 include Impl
3232}
3333
34- module BinaryToTextEncoding = {
35- type t = string
36- let base64 : t = "base64"
37- let base64url : t = "base64url"
38- let hex : t = "hex"
39- let binary : t = "binary"
40- }
34+ type binaryToTextEncoding =
35+ | @as ("base64" ) Base64
36+ | @as ("base64url" ) Base64url
37+ | @as ("hex" ) Hex
38+ | @as ("binary" ) Binary
4139
4240module PivateKey = {
4341 include KeyObject .Impl
@@ -70,7 +68,7 @@ module Hash = {
7068 @send external update : (t , Buffer .t ) => unit = "update"
7169 @send external updateString : (t , string ) => t = "update"
7270 @send external updateStringWithEncoding : (t , string , NodeJs .StringEncoding .t ) => t = "update"
73- @send external digestWithEncoding : (t , BinaryToTextEncoding . t ) => string = "digest"
71+ @send external digestWithEncoding : (t , binaryToTextEncoding ) => string = "digest"
7472 }
7573 include Impl
7674}
You can’t perform that action at this time.
0 commit comments