Removing spaces now works correctly

You see, the replacement function was only replacing the *first* space.
Now it replaces all of them. There might be a better way to do this, but
I don't know what it is :)