add missing lua 'local's