Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'prolic/barcode'
Browse files Browse the repository at this point in the history
  • Loading branch information
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Object/AbstractObject.php
Expand Up @@ -226,7 +226,7 @@ public function __construct($options = null)
if (is_array($options)) {
$this->setOptions($options);
}
$this->type = strtolower(substr(get_class($this), strlen($this->barcodeNamespace) + 1));
$this->type = strtolower(substr(get_called_class(), strlen($this->barcodeNamespace) + 1));
if ($this->mandatoryChecksum) {
$this->withChecksum = true;
$this->withChecksumInText = true;
Expand Down
2 changes: 1 addition & 1 deletion src/Object/Ean13.php
Expand Up @@ -172,7 +172,7 @@ public function getChecksum($text)
*/
protected function drawText()
{
if (get_class($this) == 'Zend\Barcode\Object\Ean13') {
if (get_called_class() == 'Zend\Barcode\Object\Ean13') {
$this->drawEan13Text();
} else {
parent::drawText();
Expand Down
2 changes: 1 addition & 1 deletion src/Renderer/AbstractRenderer.php
Expand Up @@ -110,7 +110,7 @@ public function __construct($options = null)
$this->setOptions($options);
}
$this->type = strtolower(substr(
get_class($this),
get_called_class(),
strlen($this->rendererNamespace) + 1
));
}
Expand Down

0 comments on commit 60d87e0

Please sign in to comment.