[rc.lua] Minor refactoring