FlaskFM reload page when adding or removing songs

I completed the FlaskFM project from the Learn Flask course, but I’m not sure if I did it correct. When adding or removing songs I have to reload the page to see the updated playlist, while I would expect the changes to be visible as soon as you click on the add/remove buttons.

Did I make a mistake or is this by design? I only changed the lines that required change as mentioned in the instructions.