[basics] email adress is encoded
This commit is contained in:
parent
b1c55eb1b1
commit
89b12d2dcd
|
@ -10,6 +10,7 @@ import json
|
|||
import locale
|
||||
import logging
|
||||
import subprocess
|
||||
import base64
|
||||
from datetime import date
|
||||
from pelican import readers
|
||||
from pelican import signals
|
||||
|
@ -27,6 +28,10 @@ class JSONResumeReader(readers.RstReader):
|
|||
raise Exception('please give a jsonresume metadata field for this type')
|
||||
|
||||
metadata['resume'] = json.load(open(metadata['jsonresume']))
|
||||
if 'email' in metadata['resume']['basics']:
|
||||
metadata['resume']['basics']['email'] = base64.b64encode(
|
||||
metadata['resume']['basics']['email'].encode()
|
||||
).decode()
|
||||
metadata['locale'] = self.settings.get('LOCALE', [self.settings.get('DEFAULT_LOCALE', None)])
|
||||
countryname = lambda code: 'langue'
|
||||
|
||||
|
|
Loading…
Reference in New Issue