Fix bug with empty page on first load