Expand my Community achievements bar.

The Community Ideas review for H1 2025 is out now, see which ideas our Product team prioritized and let us know your thoughts.
SOLVED

Best way to replace a character from a string

Avatar

Level 6

What is the best way to remove a character from a string? Currently I am using this implementation to remove a comma from a string. Does the emptystring variable leave unexpected characters?

Lawson02_0-1721939865667.png

 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 6

That should work.  emptystring is the same as "" in most programming languages -- a blank string of 0 length.  It is different than null and ignore, though has a "falsy" aspect to it.  (Fusion's backend is JavaScript, so you can imagine there's some overlap there.)

View solution in original post

2 Replies

Avatar

Correct answer by
Level 6

That should work.  emptystring is the same as "" in most programming languages -- a blank string of 0 length.  It is different than null and ignore, though has a "falsy" aspect to it.  (Fusion's backend is JavaScript, so you can imagine there's some overlap there.)

Avatar

Level 6

Based on some testing I had assumed that it was just that but I wanted to make sure and see if others were doing it any other way. Thanks for the quick response.