Israeli law might apply to foreign journalists operating in Israel but it would not apply to the NYT operating in the US! The NYT could have run the story without acknowledging a source or acknowledging a source outside Israel, e.g. a staff reporter.
Israeli teen lightly wounded from stone throwing in West Bank settlement of Kiryat Arba (Haaretz)
from the article: The New York Times wrestles with Israel's gag orders