Browse Source

[FormatAbstract] Allow child classes to overwrite DEFAULT_CHARSET

By using 'static' instead of 'self' the constant may
be overridden by child classes.
logmanoriginal 7 years ago
parent
commit
4f4fb11789
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/FormatAbstract.php

+ 1 - 1
lib/FormatAbstract.php

@@ -18,7 +18,7 @@ abstract class FormatAbstract implements FormatInterface {
 	public function getCharset(){
 		$charset = $this->charset;
 
-		return is_null($charset) ? self::DEFAULT_CHARSET : $charset;
+		return is_null($charset) ? static::DEFAULT_CHARSET : $charset;
 	}
 
 	protected function setContentType($contentType){