Fix warning message - incorrect variable used in logging