Load/save high score

I was loading/saveing my high score with this code before but it's no longer working:

-- Read from high score file
local scoreFile = playdate.file.open("high_score.txt", playdate.file.kFileRead)
hs = tonumber(scoreFile:readline())
scoreFile:close()

-- Write to high score file
local scoreFile = playdate.file.open("high_score.txt", playdate.file.kFileWrite)
scoreFile:write(tostring(hs))
scoreFile:close()

Any ideas why it's no longer working?

Thanks for any help,

Brian