Fixed GUI bug (added null check). Not sure if this was a problem before.