avoiding iterations and calling of underscore on all elements of array
This commit is contained in:
parent
4c76040e78
commit
7865805636
@ -90,7 +90,7 @@ def namespaced_class_path
|
||||
end
|
||||
|
||||
def namespaced_path
|
||||
@namespaced_path ||= namespace.name.split("::").map {|m| m.underscore }[0]
|
||||
@namespaced_path ||= namespace.name.split("::").first.underscore
|
||||
end
|
||||
|
||||
def class_name
|
||||
|
Loading…
Reference in New Issue
Block a user