edit missed scope
add codes in immediately invoked function