File tree Expand file tree Collapse file tree 1 file changed +1
-25
lines changed
app/code/Magento/Downloadable/Model/ResourceModel Expand file tree Collapse file tree 1 file changed +1
-25
lines changed Original file line number Diff line number Diff line change 5
5
*/
6
6
namespace Magento \Downloadable \Model \ResourceModel ;
7
7
8
- use Magento \Catalog \Api \Data \ProductInterface ;
9
- use Magento \Framework \App \ObjectManager ;
10
- use Magento \Framework \EntityManager \MetadataPool ;
11
-
12
8
/**
13
9
* Downloadable Product Samples resource model
14
10
*
17
13
*/
18
14
class Link extends \Magento \Framework \Model \ResourceModel \Db \AbstractDb
19
15
{
20
- /**
21
- * @var MetadataPool
22
- */
23
- private $ metadataPool ;
24
-
25
16
/**
26
17
* Catalog data
27
18
*
@@ -210,10 +201,7 @@ public function getSearchableData($productId, $storeId)
210
201
[]
211
202
)->join (
212
203
['cpe ' => $ this ->getTable ('catalog_product_entity ' )],
213
- sprintf (
214
- 'cpe.entity_id = m.product_id ' ,
215
- $ this ->getMetadataPool ()->getMetadata (ProductInterface::class)->getLinkField ()
216
- ),
204
+ 'cpe.entity_id = m.product_id ' ,
217
205
[]
218
206
)->joinLeft (
219
207
['st ' => $ this ->getTable ('downloadable_link_title ' )],
@@ -234,16 +222,4 @@ protected function _createCurrency()
234
222
{
235
223
return $ this ->_currencyFactory ->create ();
236
224
}
237
-
238
- /**
239
- * Get MetadataPool instance
240
- * @return MetadataPool
241
- */
242
- private function getMetadataPool ()
243
- {
244
- if (!$ this ->metadataPool ) {
245
- $ this ->metadataPool = ObjectManager::getInstance ()->get (MetadataPool::class);
246
- }
247
- return $ this ->metadataPool ;
248
- }
249
225
}
You can’t perform that action at this time.
0 commit comments