Need Javascript for Google Tag Manager expert

Job ID: 36277150

Budget: $10 – $30 AUD

To indicate you have read the description and are qualified for this job, please start your application with the following words. Any applications that do not will be ignored.
"js - tag manager - undefined error"

That means I'm NOT just looking for someone who can write javascript, I want someone who is also experienced with writing js for Google Tag Manager, AND can troubleshoot errors on the platform.

I work with Tag Manager a lot but I know nothing about javascript, so there is a good likelihood of ongoing work for the right person

THE JOB:
It's really very simple.
I need to remove a dollar sign from a variable that I have scraped from the DOM.
I have used the following code to remove the dollar sign, and the person who wrote the code assures me it should work, but it is only ever returning "undefined"
function() {
var priceText = {{Booking Price}};
var regex = /([0-9.,]+)/;
if (regex.test(priceText)) {
return priceText.match(regex)[0].replace(/,/g, '');
}
}

That code is more complex than it needs to be because it is written to remove ANY unnecessary characters from a price. ALL I need to do is to remove the left-most character OR remove dollar signs from the existing variable.

Please only bid if you are confident you can perform the job. No time-wasters!
Related categories: JavaScript Google Tag Management