Move reloading page out of callback

When running on the webserver, the callback keeps getting called and
results in a infinite loop. Hence, moved out.