BP12: Parameter validation
If your function takes parameters and the function cannot work without valid values, put in guard clauses at the start and throw an exception if they are not something you expect. ie, for null parameters throw a ArgumentNullException(nameof(param)) to indicate whats wrong. Don't let the function crash midway though or even worse, return the wrong result.