Fixed issues with calcParams