On line 14 and 15 in the uc_discounts.module, we find these two lines:
define('UC_DISCOUNTS_YES', t('yes'));
define('UC_DISCOUNTS_NO', t('no'));

This is really bad for performance.
Calling t() in globale scope forces a call to locale_refresh_cache for every page view.
We have just changed it to this for now:
define('UC_DISCOUNTS_YES', 'yes');
define('UC_DISCOUNTS_NO', 'no');

CommentFileSizeAuthor
#1 bad_performance.patch2.33 KBdawehner
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dawehner’s picture

FileSize
2.33 KB

this is something very bad, plese fix it

dawehner’s picture

Status: Active » Needs review