Skip to content

Commit 6b422dc

Browse files
author
Skr00b@!!
authored
fixed issue 11 (#12)
1 parent 61fd4b5 commit 6b422dc

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/ActionLib.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,11 @@ ActionLib.prototype.__getRoles__ = function() {
9595
callback("could not get role from data posted!");
9696
}
9797
roleReqObj = JSON.parse(postData);
98-
this.setActiveRole(roleReqObj.alias);
99-
if (! arnLib.getArn(this.getActiveRole())) {
100-
throw this.getActiveRole() + " role not found!";
98+
99+
if (! arnLib.getArn(roleReqObj.alias)) {
100+
throw roleReqObj.alias + " role not found!";
101101
} else {
102+
this.setActiveRole(roleReqObj.alias);
102103
return JSON.stringify({ active_role: this.getActiveRole() }, null, ' ');
103104
}
104105

0 commit comments

Comments
 (0)