Revert "NullPointerException"

This reverts commit 67c291b553732fdcb639b888eeabf9b395eb8c55.