[cleanup] Shorter code, fixes a warning displayed in the console