Sunan Ibn Majah, Volume 3, Book 13, Hadith 2359 (DarusSalam) ⓘ
It was narrated from Abu Hurairah that the Prophet said: “Any man who sells a product with the man who has become bankrupt, and he has not taken any of its price, it belongs to him, but if he had taken any of its price, then he is like any other creditor.”
حَدَّثَنَا هِشَامُ بْنُ عَمَّارٍ، حَدَّثَنَا إِسْمَاعِيلُ بْنُ عَيَّاشٍ، عَنْ مُوسَى بْنِ عُقْبَةَ، عَنِ الزُّهْرِيِّ، عَنْ أَبِي بَكْرِ بْنِ عَبْدِ الرَّحْمَنِ بْنِ الْحَارِثِ بْنِ هِشَامٍ، عَنْ أَبِي هُرَيْرَةَ، أَنَّ النَّبِيَّ صلى الله عليه وسلم قَالَ " أَيُّمَا رَجُلٍ بَاعَ سِلْعَةً فَأَدْرَكَ سِلْعَتَهُ بِعَيْنِهَا عِنْدَ رَجُلٍ وَقَدْ أَفْلَسَ وَلَمْ يَكُنْ قَبَضَ مِنْ ثَمَنِهَا شَيْئًا فَهِيَ لَهُ . وَإِنْ كَانَ قَبَضَ مِنْ ثَمَنِهَا شَيْئًا فَهُوَ أُسْوَةُ الْغُرَمَاءِ " .
also referenced under: Hadith 2359 (Reference) & Book 13, Hadith 52 (In-Book)