package lib import ( "errors" ) var Messages = map[string]string{ "AuthSuccess": "You have signed in successfully.", "UpdateSuccess": "Successfully updated.", "LogoutSuccess": "Bye bye!", "DeleteSuccess": "Deleted.", "GeneralSuccess": "Success!", "HackatimeLinked": "Hackatime linked.", } var Errors = map[string]error{ "InvalidCredentials": errors.New("Invalid credentials."), "AlreadyAuthenticated": errors.New("Already authenticated."), "RequireAuth": errors.New("You must be logged in to access this content."), "InvalidSession": errors.New("Session expired or invalid"), "WarnOffline": errors.New("It looks like the server is offline. Some features might not work properly."), // TODO: maybe warnings? "UserNotFound": errors.New("User not found"), "UserInvalidHandle": errors.New("That handle is invalid"), "GitInvalidBranchName": errors.New("Invalid branch name."), "GitBranchTooLong": errors.New("Branch too long!"), "GitBranchTooShort": errors.New("Branch too short!"), "GitBranchNotFound": errors.New("No such branch exists in this repo."), "GitDirectoryNotFound": errors.New("No such directory exists in this repo."), "GitRepoIsEmpty": errors.New("This repo is empty."), "IssueTitleTooLong": errors.New("That title is too long."), "IssueDescriptionTooLong": errors.New("You got the finest details written down, but your description is too long!"), "IssueCommentTooLong": errors.New("That comment is too long."), "SSHInvalidPubKey": errors.New("SSH public key is malformed or invalid"), "RepoNameTaken": errors.New("You already own a repo with that name."), }