Closed vbhayden closed 1 month ago
Failed conditions
100.0% Duplication on New Code (required ≤ 3%)
The isAdmin()
check in cassUtil.js
seems to be unused, as that function didn't seem to do anything when changed. I can remove that block there to keep SonarCoud from complaining about duplication if requested.
Updating the two
isAdmin()
functions to compare all public keys for the current user against all admin public keys provided by the ping.The original check just looked at the first key in both, and the updated ping response will also include known users who have logged in as admins since the server process started.
This is a sister PR for https://github.com/cassproject/CASS/pull/320