This repository has been archived by the owner on Sep 7, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(errors): defining errors in proper way
- Loading branch information
Showing
24 changed files
with
122 additions
and
109 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,12 @@ | ||
# Compiled binary files | ||
*.exe | ||
*.out | ||
*.dll | ||
*.so | ||
*.dylib | ||
|
||
# Compiled object files | ||
*.o | ||
|
||
# Go binary and test coverage reports | ||
*.test | ||
*.prof | ||
|
||
# Dependency directories (remove these if using Go modules) | ||
/vendor/ | ||
/Godeps/ | ||
|
||
# Ignore IDE and editor-specific files | ||
.vscode/ | ||
.idea/ | ||
*.sublime-project | ||
*.sublime-workspace | ||
|
||
# OS-specific files | ||
.DS_Store | ||
Thumbs.db | ||
|
||
# dev files | ||
cmd/config.yaml | ||
/client | ||
log.ttrace | ||
build/ | ||
# Development files | ||
client | ||
build | ||
|
||
# python cache files | ||
test/__pycache__ | ||
# Cache files | ||
*cache* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package commands | ||
|
||
import "fmt" | ||
|
||
type InvalidAuthInfoError struct { | ||
command string | ||
} | ||
|
||
func (e InvalidAuthInfoError) Error() string { | ||
return fmt.Sprintf("command %s is not a valid command to authenticate", e.command) | ||
} | ||
|
||
type InvalidConfigPathError struct { | ||
path string | ||
} | ||
|
||
func (e InvalidConfigPathError) Error() string { | ||
return fmt.Sprintf("path %s doesn't contain a valid config file", e.path) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package config | ||
|
||
import "fmt" | ||
|
||
type BasicCheckError struct { | ||
reason string | ||
} | ||
|
||
func (e BasicCheckError) Error() string { | ||
return fmt.Sprintf("config basic check failed: %s", e.reason) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package server | ||
|
||
import "fmt" | ||
|
||
type AuthenticateError struct { | ||
reason string | ||
} | ||
|
||
func (e AuthenticateError) Error() string { | ||
return fmt.Sprintf("auth error: %s", e.reason) | ||
} |
Oops, something went wrong.