I've investigated issue and solution is to remove commented lines:
if(!in_array($type, $notify)) {
if($type == OSP_TYPE_PREMIUM) {
$content['s_text'] = preg_replace('|{START_PREMIUM}(.*){END_PREMIUM}|', '', $content['s_text']);
} else if($type == OSP_TYPE_HIGHLIGHT) {
$content['s_text'] = preg_replace('|{START_HIGHLIGHT}(.*){END_HIGHLIGHT}|', '', $content['s_text']);
} else if($type == OSP_TYPE_REPUBLISH) {
$content['s_text'] = preg_replace('|{START_REPUBLISH}(.*){END_REPUBLISH}|', '', $content['s_text']);
//} else {
// return false;
}
}
}
so correct code is:
if(!in_array($type, $notify)) {
if($type == OSP_TYPE_PREMIUM) {
$content['s_text'] = preg_replace('|{START_PREMIUM}(.*){END_PREMIUM}|', '', $content['s_text']);
} else if($type == OSP_TYPE_HIGHLIGHT) {
$content['s_text'] = preg_replace('|{START_HIGHLIGHT}(.*){END_HIGHLIGHT}|', '', $content['s_text']);
} else if($type == OSP_TYPE_REPUBLISH) {
$content['s_text'] = preg_replace('|{START_REPUBLISH}(.*){END_REPUBLISH}|', '', $content['s_text']);
}
}
}
also email template must contain keyword strings: START_PREMIUM, END_PREMIUM, .... otherwise it will not work (those cannot be translated).