9 lines
250 B
Python
9 lines
250 B
Python
|
from base64 import b64encode as _b64encode
|
||
|
from os.path import isfile as _isfile
|
||
|
|
||
|
|
||
|
def get_logo(filename):
|
||
|
if not _isfile(filename):
|
||
|
raise Exception(f'cannot find odoo logo {filename}')
|
||
|
return _b64encode(open(filename, 'rb') .read())
|