Some parameters were not optional, which caused warnings. Corrected.