Setting current scope before calling transform