Catch for converting strings to nullable type