Skip to content

Commit 2abd097

Browse files
authored
Merge pull request #229 from AlainODea/ao-BUG-env-mode-no-sessions
🐛 Current session used in OKTA_ENV_MODE
2 parents b14e882 + 883d275 commit 2abd097

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/main/java/com/okta/tools/helpers/SessionHelper.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ public SessionHelper(OktaAwsCliEnvironment environment, CookieHelper cookieHelpe
3434
* @throws IOException if file system or permissions errors are encountered
3535
*/
3636
public Optional<Session> getCurrentSession() throws IOException {
37+
if (environment.oktaEnvMode) return Optional.empty();
3738
if (Files.exists(getSessionPath())) {
3839
try (FileReader fileReader = new FileReader(getSessionPath().toFile())) {
3940
Properties properties = new Properties();

0 commit comments

Comments
 (0)