Fix direct edit issue