Changed success function scope