Added null checker for safety