···16161717- All functions now use `prepend_header` instead of `set_header`.
1818- Renamed `did.DidError` to `did.ParseError`
1919+- Rename `did.InvalidFormat` to `did.InvalidSyntax`
2020+- Rename `handle.InvalidFormat` to `handle.InvalidSyntax`
+2-2
src/possum/did.gleam
···2020 /// Regex failed to compile
2121 InvalidRegexPattern(pattern: String)
2222 /// String does not have a valid DID format
2323- InvalidFormat(value: String)
2323+ InvalidSyntax(value: String)
2424 /// Method can only be "plc" or "web"
2525 InvalidDidMethod(value: String)
2626}
···135135136136 use value <- result.try(case regexp.check(with:, content:) {
137137 True -> Ok(content)
138138- False -> Error(InvalidFormat(content))
138138+ False -> Error(InvalidSyntax(content))
139139 })
140140141141 case string.trim(value) {
+2-2
src/possum/handle.gleam
···1515 /// Regex failed to compile
1616 InvalidRegexPattern(pattern: String)
1717 /// String does not have a valid handle format
1818- InvalidFormat(value: String)
1818+ InvalidSyntax(value: String)
1919 /// "Reserved" top-level domains should not fail syntax validation,
2020 /// but they must immediately fail any attempt at registration.
2121 ///
···53535454 use value <- result.try(case regexp.check(with:, content:) {
5555 True -> Ok(content)
5656- False -> Error(InvalidFormat(content))
5656+ False -> Error(InvalidSyntax(content))
5757 })
58585959 use value <- result.map(check_invalid_domains(value))