diff options
author | 2023-11-30 16:22:34 +0000 | |
---|---|---|
committer | 2023-11-30 16:22:34 +0000 | |
commit | eb170003b81504ba6eb85f950c223dc9eaf1cfca (patch) | |
tree | f1f9779e14875faa70f4db85a8cf19100633884d /vendor/codeberg.org/gruf/go-errors/v2/error.go | |
parent | [bugfix] always go through status parent dereferencing on isNew, even on data... (diff) | |
download | gotosocial-eb170003b81504ba6eb85f950c223dc9eaf1cfca.tar.xz |
[bugfix] return 400 Bad Request on more cases of malformed AS data (#2399)
Diffstat (limited to 'vendor/codeberg.org/gruf/go-errors/v2/error.go')
-rw-r--r-- | vendor/codeberg.org/gruf/go-errors/v2/error.go | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/vendor/codeberg.org/gruf/go-errors/v2/error.go b/vendor/codeberg.org/gruf/go-errors/v2/error.go deleted file mode 100644 index ed1217a29..000000000 --- a/vendor/codeberg.org/gruf/go-errors/v2/error.go +++ /dev/null @@ -1,35 +0,0 @@ -//go:build !notrace -// +build !notrace - -package errors - -type errormsg struct { - msg string - wrap error - stack Callers -} - -func create(msg string, wrap error) *errormsg { - return &errormsg{ - msg: msg, - wrap: wrap, - stack: GetCallers(2, 10), - } -} - -func (err *errormsg) Error() string { - return err.msg -} - -func (err *errormsg) Is(target error) bool { - other, ok := target.(*errormsg) - return ok && (err.msg == other.msg) -} - -func (err *errormsg) Unwrap() error { - return err.wrap -} - -func (err *errormsg) Stacktrace() Callers { - return err.stack -} |