Convert parameter to string before checking if it is empty.