reafctor and audit fn with now be passed the params from the url, if any.