Some updates to try and debug nullPointerException