Improved project structure

This commit is contained in:
Eduard Urbach 2023-10-20 17:07:44 +02:00
parent 3a002a7562
commit bd73132a30
Signed by: eduard
GPG key ID: 49226B848C78F6C8
18 changed files with 33 additions and 15 deletions

15
src/errors/InvalidPath.go Normal file
View file

@ -0,0 +1,15 @@
package errors
import "fmt"
type InvalidDirectory struct {
Path string
}
func (err *InvalidDirectory) Error() string {
if err.Path == "" {
return "Invalid directory"
}
return fmt.Sprintf("Invalid directory '%s'", err.Path)
}