Fix null string bug

Thanks @smurfofsmurf