Handle undef case properly