No plugins present results in invalid session

Description

When no plugins are present the Course tries to retrieve a non existent first lesson. We probably need to put up a help screen or error text that denotes that there are no lessons in the WebGoat container.

java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:635)
at java.util.ArrayList.get(ArrayList.java:411)
at org.owasp.webgoat.session.Course.getFirstLesson(Course.java:179)
at org.owasp.webgoat.session.WebSession.update(WebSession.java:805)
at org.owasp.webgoat.HammerHead.updateSession(HammerHead.java:403)
at org.owasp.webgoat.HammerHead.doPost(HammerHead.java:131)
at org.owasp.webgoat.HammerHead.doGet(HammerHead.java:106)

Environment

None

Status

Assignee

BruceM

Reporter

BruceM

Labels

None

Sprint

Fix versions

Priority

Major