Removed RCS-style IDs.
[redact.git] / lib / redact / program.rb
index a77536748aab2b036a9729dd6e33977d29acef77..abcc79e8a9bb7572415ec3fce8ebf83974b17196 100644 (file)
@@ -1,6 +1,4 @@
 #--
-# $Id: program.rb 28 2005-04-14 19:53:45Z tilman $
-#
 # Copyright (c) 2005 Tilman Sauerbeck (tilman at code-monkey de)
 #
 # Permission is hereby granted, free of charge, to any person obtaining
@@ -181,8 +179,8 @@ module Redact
                        super
 
                        @type = TYPE_EMIT_SIGNAL
-                       @emission_signal = nil
-                       @emission_source = nil
+                       @emission_signal = ""
+                       @emission_source = ""
                end
 
                def emission_signal=(v)
@@ -212,7 +210,8 @@ module Redact
                end
 
                def script=(v)
-                       @script = v.to_str.dup
+                       v = v.to_str
+                       @script = (File.exist?(v) ? File.read(v) : v).dup
                end
        end