old_sql 1.58.0 → 1.59.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -63,7 +63,7 @@ module OldSql
|
|
|
63
63
|
|
|
64
64
|
def configure_initializer
|
|
65
65
|
initializer_path = "#{app_path}/config/initializers/old_sql.rb"
|
|
66
|
-
gsub_file initializer_path, /DeviseModel/, "#{model_name.downcase}"
|
|
66
|
+
gsub_file initializer_path, /DeviseModel/, "#{model_name.singularize.downcase}"
|
|
67
67
|
end
|
|
68
68
|
|
|
69
69
|
################ PRIVATE ################
|
|
@@ -141,8 +141,8 @@ module OldSql
|
|
|
141
141
|
def add_devise_to_routes
|
|
142
142
|
routes_path = "#{app_path}/config/routes.rb"
|
|
143
143
|
if open(routes_path).grep(/devise_for :#{model_name}/).count<=0
|
|
144
|
-
puts "Adding devise_for :#{model_name} to #{routes_path}"
|
|
145
|
-
insert_into_file routes_path, " devise_for :#{model_name}\n\n", :after => "Application.routes.draw do\n"
|
|
144
|
+
puts "Adding devise_for :#{model_name.singularize} to #{routes_path}"
|
|
145
|
+
insert_into_file routes_path, " devise_for :#{model_name.singularize}\n\n", :after => "Application.routes.draw do\n"
|
|
146
146
|
end
|
|
147
147
|
end
|
|
148
148
|
|
metadata
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: old_sql
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
4
|
prerelease:
|
|
5
|
-
version: 1.
|
|
5
|
+
version: 1.59.0
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
8
8
|
- Eddie Gonzales
|
|
@@ -198,7 +198,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
198
198
|
requirements:
|
|
199
199
|
- - ">="
|
|
200
200
|
- !ruby/object:Gem::Version
|
|
201
|
-
hash: -
|
|
201
|
+
hash: -2722313713856130498
|
|
202
202
|
segments:
|
|
203
203
|
- 0
|
|
204
204
|
version: "0"
|