I believe it is necessary to prevent the page from reloading