Money function but what if it is empty?

Ello, In the documentation i am reading there is a money function but if the value isn't a int or float you get a error,
Is there anyway if the field is empty you could disable the function or something in that way
image.png
Solution
  TextColumn::make('price')->getStateUsing(fn ($record) =>
                     is_null($record->price) ? '-' : '€' . number_format($record->price, 2, '.', '')
                ),

Final result 😄
Was this page helpful?