summaryrefslogtreecommitdiffstats
path: root/vendor
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2010-04-18 10:00:11 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2010-04-18 10:00:11 +0000
commit760c933bd7f9cef23f5a50422a123a09f45b2389 (patch)
tree94f043216112a8343821f243906973f85c3ab948 /vendor
parent3bf6790826f5740f79713a05eb9524735ca39b8d (diff)
downloadredmine-760c933bd7f9cef23f5a50422a123a09f45b2389.tar.gz
redmine-760c933bd7f9cef23f5a50422a123a09f45b2389.zip
Fixes acts_as_event with a String as url option (#5343).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3681 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'vendor')
-rw-r--r--vendor/plugins/acts_as_event/lib/acts_as_event.rb10
1 files changed, 9 insertions, 1 deletions
diff --git a/vendor/plugins/acts_as_event/lib/acts_as_event.rb b/vendor/plugins/acts_as_event/lib/acts_as_event.rb
index 1aa7ddf01..364bb8cef 100644
--- a/vendor/plugins/acts_as_event/lib/acts_as_event.rb
+++ b/vendor/plugins/acts_as_event/lib/acts_as_event.rb
@@ -65,7 +65,15 @@ module Redmine
def event_url(options = {})
option = event_options[:url]
- (option.is_a?(Proc) ? option.call(self) : send(option)).merge(options)
+ if option.is_a?(Proc)
+ option.call(self)
+ elsif option.is_a?(Hash)
+ option.merge(options)
+ elsif option.is_a?(Symbol)
+ send(option)
+ else
+ option
+ end
end
# Returns the mail adresses of users that should be notified