In general it is not a problem that your functions throw this error. Its a warning sign that there's something wrong with the code that is calling these functions. If you really want to allow these functions to accept less than the required parameters then you should be using $foo = 0 if not defined $foo; settings.