diff options
| author | hhvn <dev@hhvn.uk> | 2023-08-14 14:04:41 +0100 |
|---|---|---|
| committer | hhvn <dev@hhvn.uk> | 2023-08-14 14:47:38 +0100 |
| commit | 79a80fbbf278e0eb743a79e2c0c252817537434f (patch) | |
| tree | 7704e968ec2071a931140b43f6ec2ea61ed1d527 /common/common.go | |
| parent | 0543020038edb5de1162863e7401ea36f8a8584c (diff) | |
Creating and destroying the windows
Diffstat (limited to 'common/common.go')
| -rw-r--r-- | common/common.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/common/common.go b/common/common.go index 20c2c0a..00d58ee 100644 --- a/common/common.go +++ b/common/common.go @@ -12,11 +12,7 @@ func Perror(function string, err error) error { func Error(format string, a ... any) (int, error) { fmt.Fprintf(os.Stderr, "error: ") - if (len(a) == 0) { - return fmt.Fprintf(os.Stderr, format) - } else { - return fmt.Fprintf(os.Stderr, format, a) - } + return fmt.Fprintf(os.Stderr, format, a...) } func Intify(s string) (int, error) { |