Al-Hijr • EN-AL-JALALAYN
﴿ وَمَآ أَهْلَكْنَا مِن قَرْيَةٍ إِلَّا وَلَهَا كِتَابٌۭ مَّعْلُومٌۭ ﴾
“And never have We destroyed any community [for its wrongdoing] unless a divine writ had (previously] been made known to it;”
And We did not destroy any town min qaryatin min is extra meaning its inhabitants but that it had a known decree a pre-determined term after which it would be destroyed.