LPS-36711 Rename variables
LPS-36711 Fix possible NPE