Bladeren bron

update: mac Job

Mark24 2 jaren geleden
bovenliggende
commit
349a593d5f
1 gewijzigde bestanden met toevoegingen van 3 en 4 verwijderingen
  1. 3 4
      mac.rb

+ 3 - 4
mac.rb

@@ -25,13 +25,12 @@ class String
 end
 
 class Job
-  attr_accessor :status
+  attr_accessor :status, :intro
   def initialize
     @status = :waiting # :processing, :done, :fail
+    @intro = self.class.to_s.sub(/Job$/, "")
   end
-  def intro
-    self.class.to_s
-  end
+
   def call
   end