def _get_signer(app): if not app.secret_key: return None return Signer(app.secret_key, salt='flask-sessions', key_derivation='hmac')