From 7f8317ac9f5bff192e6355ef1be1533b0726ef05 Mon Sep 17 00:00:00 2001 From: Christian A. Weber Date: Sat, 25 Jul 2020 12:52:17 +0200 Subject: don't trigger legacy warning if both username and uid are empty --- it_user.class | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'it_user.class') diff --git a/it_user.class b/it_user.class index 7ebdc9f..3bb9c3a 100644 --- a/it_user.class +++ b/it_user.class @@ -93,7 +93,7 @@ function read($id = null) $this->username = $this->{$this->p['username_field']}; # username == uid means we don't have a username yet - if ($this->username == $this->uid) # FIXME 2020-12 CS Remove support for legacy user records with username = uid + if ($this->username && $this->username == $this->uid) # FIXME 2020-12 CS Remove support for legacy user records with username = uid { it::error(['to' => 'schneider@search.ch', 'title' => "Legacy user record with username = uid ($this->uid)"]); $this->username = ""; -- cgit v1.2.3