Ayesha reported,

She informed him that she had asked the Messenger of Allah ﷺ about the plague, and he said, "It was a punishment that Allah would send upon whomever He willed, but Allah made it a mercy for the believers. There is no servant who, finding himself in a land where the plague has broken out, remains there patiently seeking reward, knowing that nothing will befall him except what Allah has decreed for him, except that he will receive a reward like that of a martyr."

Bukhari 6619

Sahih

حدثني إسحاق بن إبراهيم الحنظلي أخبرنا النضر حدثنا داود بن أبي الفرات عن عبد الله بن بريدة عن يحيى بن يعمر أن

عائشة رضي الله عنها

أخبرته أنها سألت رسول الله ﷺ عن الطاعون فقال كان عذابا يبعثه الله على من يشاء فجعله الله رحمة للمؤمنين ما من عبد يكون في بلد يكون فيه ويمكث فيه لا يخرج من البلد صابرا محتسبا يعلم أنه لا يصيبه إلا ما كتب الله له إلا كان له مثل أجر شهيد

البخاري 6619صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Decree
Chapter
"Say, nothing will befall us except what Allah has decreed for us", ordained
Numbering
Darussalam 6619
Bukhari 6619