Skip to content

Commit ef88382

Browse files
committed
Fixed issue with getProject returning wrong project
The function getProject should return the project to search for when you pass the name parameter instead it returns the first element the projects tuple on the whole workspace.
1 parent 0e68805 commit ef88382

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pyral/restapi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ def getProject(self, name=None):
433433
hits = [(proj,ref) for proj,ref in projs if str(proj) == str(name)]
434434
if not hits:
435435
return None
436-
tp = projs[0]
436+
tp = hits[0]
437437
tp_ref = tp[1]
438438
return _createShellInstance(context, 'Project', name, tp_ref)
439439

0 commit comments

Comments
 (0)