lib/rspeckled/plugins/authentication.rb in rspeckled-0.0.31 vs lib/rspeckled/plugins/authentication.rb in rspeckled-0.0.32
- old
+ new
@@ -17,13 +17,13 @@
options[:class] || User
else
options
end
- underscored_class_name = klass.
- name[/(?:.*::)?(\w+)\z/, 1].
- gsub(/([a-z])([A-Z])/, '\1_\2').
- downcase
+ underscored_class_name = klass
+ .name[/(?:.*::)?(\w+)\z/, 1]
+ .gsub(/([a-z])([A-Z])/, '\1_\2')
+ .downcase
current_class_method = if options.is_a?(Hash) && options[:method]
options[:method] || :current_user
else
:"current_#{underscored_class_name}"