Fix #31 and #32 remove useless null checks