Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-shell
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-shell
Commits
4853c677
Commit
4853c677
authored
Aug 07, 2013
by
Julian K
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update gitlab_shell.rb
using instance_variable_defined to avoid @user_tried
parent
d3c3fbc6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
3 deletions
+1
-3
lib/gitlab_shell.rb
lib/gitlab_shell.rb
+1
-3
No files found.
lib/gitlab_shell.rb
View file @
4853c677
...
...
@@ -10,7 +10,6 @@ class GitlabShell
@origin_cmd
=
ENV
[
'SSH_ORIGINAL_COMMAND'
]
@config
=
GitlabConfig
.
new
@repos_path
=
@config
.
repos_path
@user_tried
=
false
end
def
exec
...
...
@@ -70,10 +69,9 @@ class GitlabShell
def
user
# Can't use "@user ||=" because that will keep hitting the API when @user is really nil!
if
@user_tried
if
instance_variable_defined?
(
'@user'
)
@user
else
@user_tried
=
true
@user
=
api
.
discover
(
@key_id
)
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment