Closed joshuasorkin closed 2 years ago
The problem is in https://github.com/shotstack-samples/build-me-a-video-twitter-bot/blob/main/handlers/process/lib/render.js, line 13:
newString = string.replace(/'/g, '"');
This should instead be:
newString = string.replace(/'/g, ''');
or
newString = string.replace(/'/g, '’');
The latter is if you want to use a curly apostrophe ( ’ ), which I think actually looks more professional in the final render. Interestingly, actually using a curly apostrophe in the tweet is a workaround, as it isn't a reserved character and passes through the render function unchanged.
This is a really easy fix; I'd be happy to submit a PR for this if you like.
Good pickup. Didn't think of that one.
Yeah feel free submit a PR and I'll merge and deploy.
I'm getting a 403 on my end when I try git push origin apostrophe-fix
; maybe you have to add me to the repo as a contributor?
EDIT: never mind, I forked it and pushed to my remote instead of trying to push to yours, and that solved the problem
Good pickup. Didn't think of that one.
Yeah feel free submit a PR and I'll merge and deploy.
PR submitted.
Sweet thanks. Have merged and deployed. Changes are now live!
to replicate: