NPE and course deletion added.