moved parseParamters method to the top