Skip to content

Commit

Permalink
Change split to stop after 2 delimeters
Browse files Browse the repository at this point in the history
  • Loading branch information
joeyw committed Jan 10, 2016
1 parent c088f33 commit 0317f5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/octokit/repository.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class Repository
def self.from_url(url)
new URI.parse(url).path[1..-1].
gsub(/^repos\//,'').
split('/')[0..1].
split('/', 3)[0..1].
join('/')
end

Expand Down

0 comments on commit 0317f5b

Please sign in to comment.