added a if visitation
added missing lib RewriteCore