Salama bin Akwa reported,

When this verse was revealed, "And upon those who are able to fast, but with hardship, a ransom of feeding a poor person" [Baqarah 2:184], whoever wished could break his fast and pay the ransom, until the verse that came after it was revealed and abrogated it.In another wording, during Ramadan in the time of the Messenger of Allah ﷺ, whoever wished would fast and whoever wished would break his fast and pay a ransom by feeding a poor person, until this verse was revealed, "So whoever among you witnesses the month, let him fast it" [Baqarah 2:185].

Azami 4298

Sahih

عن سلمة بن الأكوع، قال

لما نزلت هذه الآية: {وعلى الذين يطيقونه فدية طعام مسكين} [البقرة: ١٨٤] كان من أراد أن يفطر ويفتدي، حتى نزلت الآية التي بعدها، فنسختها. وفي لفظ: كنا في رمضان على عهد رسول الله ﷺ من شاء صام، ومن شاء أفطر فافتدى بطعام مسكين، حتى أنزلت هذه الآية {فمن شهد منكم الشهر فليصمه} [البقرة: ١٨٥].

الأعظمي 4298صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Fasting
Chapter
Obligation of fasting, its virtue, and its rulings
Section
Abrogation of His saying, "And upon those who are able to fast it is a fidya of feeding a poor person"
Numbering
Jami al-Kamil 4298 (2nd edition)
Azami 4298