added same check and imcrementation to page_referenced_one function, i think that's its name