Move deserialize out of signer.js