We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5d9f5d4 commit 3f9722aCopy full SHA for 3f9722a
src/app/code/community/Zendesk/Zendesk/Helper/Data.php
@@ -229,8 +229,16 @@ public function getOrderDetail($order)
229
230
public function getSupportEmail($store = null)
231
{
232
+ // Serves as the dafault email
233
$domain = Mage::getStoreConfig('zendesk/general/domain', $store);
234
$email = 'support@' . $domain;
235
+
236
+ // Get the actual default email from the API, return the default if somehow none is found
237
+ $defaultRecipient = Mage::getModel('zendesk/api_supportAddresses')->getDefault();
238
239
+ if (!is_null($defaultRecipient)) {
240
+ $email = $defaultRecipient['email'];
241
+ }
242
243
return $email;
244
}
0 commit comments