Skip to content

Commit fb29ecf

Browse files
author
Dominic
committed
add type resolve sting to const
1 parent d6dad52 commit fb29ecf

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

app/code/Magento/ConfigurableProductGraphQl/Model/ConfigurableProductTypeResolver.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,19 @@
1515
*/
1616
class ConfigurableProductTypeResolver implements TypeResolverInterface
1717
{
18+
/**
19+
* Configurable product type resolver code
20+
*/
21+
const TYPE_RESOLVER = 'ConfigurableProduct';
22+
1823
/**
1924
* {@inheritdoc}
2025
*/
2126
public function resolveType(array $data) : string
2227
{
2328
if (isset($data['type_id']) && $data['type_id'] == Type::TYPE_CODE) {
24-
return 'ConfigurableProduct';
29+
return self::TYPE_RESOLVER;
30+
2531
}
2632
return '';
2733
}

0 commit comments

Comments
 (0)