gollum_rails 1.5.6 → 1.5.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/gollum_rails.gemspec +1 -1
- data/lib/gollum_rails.rb +1 -1
- data/lib/gollum_rails/core.rb +2 -2
- data/spec/gollum_rails/page_spec.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 67b3c438988077db91126e6420ed6b545991a35a
|
4
|
+
data.tar.gz: c782264918b108551c5b93926108a5b8e4944944
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b29976c1d9eabc38a760a20a89767e6e01e89dc0b5deabcac45de975da698710c494592f877d334c3d56283c5b56986602651f0b9646bd5c98ca2341eccbe750
|
7
|
+
data.tar.gz: 7c8177eb33d8452c685c6262da5b59e087c62be3f61f21e337e246225087cd02ba9e231dbad61f9ef675364eb3a424c44a83c7d29c1b721d29bd4473de0d4330
|
data/Gemfile.lock
CHANGED
data/gollum_rails.gemspec
CHANGED
data/lib/gollum_rails.rb
CHANGED
data/lib/gollum_rails/core.rb
CHANGED
@@ -63,8 +63,8 @@ module GollumRails
|
|
63
63
|
|
64
64
|
# Gets the next subfolder for current pathname
|
65
65
|
def next_folder(previous)
|
66
|
-
path =
|
67
|
-
previous = File.split(previous).join
|
66
|
+
path = url
|
67
|
+
previous = File.split(previous).join('/').gsub(/^\/+/, '')
|
68
68
|
path.gsub!(/#{previous}/i, '')
|
69
69
|
ngxpath = File.split(path).first #use path only cuz we want the next folder not file
|
70
70
|
new_path = ngxpath.split('/').reject { |c| c.empty? }
|
@@ -89,7 +89,7 @@ describe "Gollum Page" do
|
|
89
89
|
it "can get the next subfolder" do
|
90
90
|
@rr.name = '/home/page/test/page'
|
91
91
|
@rr.save
|
92
|
-
expect(@rr.next_folder('/home')).to match '
|
92
|
+
expect(@rr.next_folder('/home/page')).to match 'test'
|
93
93
|
@rr.destroy
|
94
94
|
end
|
95
95
|
it "can get the next subfolder again" do
|