Closed AaronDewes closed 3 months ago
Thank you so much to take your time out and make a PR Aaron!
I actually tried that too but I am not able to solve the error. Will try more methods and will update
@AaronDewes Actually the rest api for contents of github repo is returning the yml file contents in base64 string. But ocktokit is decoding it and giving it in a string format of utf-8. So as I was mocking the api call, I was replying with base64. When I changed it to be in utf-8, it worked!
fs.readFileSync already returns a buffer. Doing
Buffer.from
seems to implicitly convert it to a string and cause the issue at https://github.com/probot/probot/issues/2030