do not pass null in as the last argument to str_replace (PHP8.1 does not like this)

This commit is contained in:
David Goodwin committed 2022-12-04 20:38:46 +00:00
1 parent 667de0938b
commit b27001cc52
1 file changed
+5 -2
+5 -2
View File
@@ -450,8 +450,11 @@ class AliasHandler extends PFAHandler {
* @return string an email alias.
*/
protected function getVacationAlias() {
$vacation_goto = str_replace('@', '#', $this->id);
return $vacation_goto . '@' . Config::read_string('vacation_domain');
if ($this->id !== null) {
$vacation_goto = str_replace('@', '#', $this->id);
return $vacation_goto . '@' . Config::read_string('vacation_domain');
}
return "unknown@" . Config::read_string('vacation_domain');
}
/**