]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - data/rbot/plugins/url.rb
Module\#define_structure method: define a new Struct only if doesn't exist already...
[user/henk/code/ruby/rbot.git] / data / rbot / plugins / url.rb
index 62fc55888980bb15b5ab9e261b735b6a1f57b087..092ccbf99ca7ebbe0fd425dd7515014a418d7b2e 100644 (file)
@@ -1,4 +1,4 @@
-Url = Struct.new("Url", :channel, :nick, :time, :url, :info)
+define_structure :Url, :channel, :nick, :time, :url, :info
 
 class ::UrlLinkError < RuntimeError
 end