summaryrefslogtreecommitdiffstats
path: root/lib/private/legacy/defaults.php
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2017-03-28 13:29:59 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2017-03-29 18:23:23 +0200
commit698396a9270af9aaecf77411622efb7980b68886 (patch)
treeb8af2e5ebe1cd3cb01de674c3347fb2514383fd4 /lib/private/legacy/defaults.php
parent9a75714c22b406ef13c985bec567b9d88ce7dc84 (diff)
downloadnextcloud-server-698396a9270af9aaecf77411622efb7980b68886.tar.gz
nextcloud-server-698396a9270af9aaecf77411622efb7980b68886.zip
Add fallback to getMailHeaderColor so we don't break existing themes
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'lib/private/legacy/defaults.php')
-rw-r--r--lib/private/legacy/defaults.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/private/legacy/defaults.php b/lib/private/legacy/defaults.php
index 0248af54691..d06bbbd21e7 100644
--- a/lib/private/legacy/defaults.php
+++ b/lib/private/legacy/defaults.php
@@ -276,11 +276,14 @@ class OC_Defaults {
* @return string
*/
public function getColorPrimary() {
+
if ($this->themeExist('getColorPrimary')) {
return $this->theme->getColorPrimary();
- } else {
- return $this->defaultMailHeaderColor;
}
+ if ($this->themeExist('getMailHeaderColor')) {
+ return $this->theme->getMailHeaderColor();
+ }
+ return $this->defaultMailHeaderColor;
}
public function shouldReplaceIcons() {