fix the scope resolved issues