lib/rasti/app/utils.rb in rasti-app-7.0.1 vs lib/rasti/app/utils.rb in rasti-app-7.0.2
- old
+ new
@@ -19,9 +19,13 @@
def namespace_of(klass)
namespace = klass.name.split('::')[0..-2].join('::')
namespace.empty? ? nil : Object.const_get(namespace)
end
+ def split_hash(hash, keys)
+ [hash.slice(*keys), hash.slice(*(hash.keys - keys))]
+ end
+
end
end
end
end
\ No newline at end of file