summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/band.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/band.rb b/lib/band.rb
index e75dd6e..59e7541 100644
--- a/lib/band.rb
+++ b/lib/band.rb
@@ -41,6 +41,10 @@ class Band
end
def validate!
+ if @name.nil? || @name.strip.empty?
+ errors << "Bandnavn mangler"
+ end
+
if @songs.length <= 0
errors << "Du må ha med minst én låt!"
end