Id use a simple else for that. Everything thats not an array or object is a string or number.