Well, I assumed that you are using our Child Theme. If you are not using Child Theme, the changes will disappear every update.
Your solution looks reasonable, glad that it works. And of course we will consider adding that feature in the future. I’ll let you know.