add excel extension

This commit is contained in:
Omair Saleh
2022-10-19 10:35:54 +08:00
parent a472ec6684
commit 2f1164d606
@@ -66,7 +66,7 @@ class FileObject implements DataTransferObject
*/
public function getDecodedData(): string
{
return $this->getExtension() === 'pdf' ?
return in_array($this->getExtension(), ['pdf', 'excel']) ?
base64_decode((explode('base64,', $this->getData()))[1]):
$this->getData()->encode('data-url')->encoded;
}