Skip to content

Commit d2320b4

Browse files
committed
Update Module.php
Added getCertificate() method.
1 parent d1fa31f commit d2320b4

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/Module.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,14 @@ public function setCertificate($certificate)
264264
$this->padesModule->setCertificate($certificate);
265265
}
266266

267+
/**
268+
* @return \SetaPDF_Signer_X509_Certificate|string
269+
*/
270+
public function getCertificate()
271+
{
272+
return $this->padesModule->getCertificate();
273+
}
274+
267275
/**
268276
* @param string $signatureAlgorithmOid
269277
*/
@@ -349,7 +357,7 @@ public function getCms()
349357
public function createSignature(SetaPDF_Core_Reader_FilePath $tmpPath)
350358
{
351359
// ensure certificate
352-
$certificate = $this->padesModule->getCertificate();
360+
$certificate = $this->getCertificate();
353361
if ($certificate === null) {
354362
throw new \BadMethodCallException('Missing certificate!');
355363
}

0 commit comments

Comments
 (0)