Final commit

fixed a last minute null pointer exception