Small code simplification

Author: Nathan Bossart <nathandbossart@gmail.com>
Discussion: https://www.postgresql.org/message-id/20230310000313.GA3992372%40nathanxps13
This commit is contained in:
Peter Eisentraut 2023-03-16 15:33:43 +01:00
parent 4ef1be5a0b
commit 3b7cd8c690
1 changed files with 1 additions and 1 deletions

View File

@ -1378,7 +1378,7 @@ RenameRole(const char *oldname, const char *newname)
* Only superusers can mess with superusers. Otherwise, a user with
* CREATEROLE can rename a role for which they have ADMIN OPTION.
*/
if (((Form_pg_authid) GETSTRUCT(oldtuple))->rolsuper)
if (authform->rolsuper)
{
if (!superuser())
ereport(ERROR,