dddp/accounts/ddp.py
def deserialize_profile(profile, key_prefix='', pop=False):
        """De-serialize user profile fields into concrete model fields."""
        result = {}
        if pop:
            getter = profile.pop
        else:
            getter = profile.get

        def prefixed(name):
            """Return name prefixed by `key_prefix`."""
            return '%s%s' % (key_prefix, name)

        for key in profile.keys():
            val = getter(key)
            if key == prefixed('name'):
                result['full_name'] = val
            else:
                raise MeteorError(400, 'Bad profile key: %r' % key)
        return result
def deserialize_profile(profile, key_prefix='', pop=False):
        result = {}
        if pop:
            getter = profile.pop
        else:
            getter = profile.get

        def prefixed(name):
            """Return name prefixed by `key_prefix`."""
            return '%s%s' % (key_prefix, name)

        for key in profile.keys():
            val = getter(key)
            if key == prefixed('name'):
                result['full_name'] = val
            else:
                raise MeteorError(400, 'Bad profile key: %r' % key)
        return result
def deserialize_profile ( profile , key_prefix = '' , pop = False ) : result = { } if pop : getter = profile . pop else : getter = profile . get def prefixed ( name ) : """Return name prefixed by `key_prefix`.""" return '%s%s' % ( key_prefix , name ) for key in profile . keys ( ) : val = getter ( key ) if key == prefixed ( 'name' ) : result [ 'full_name' ] = val else : raise MeteorError ( 400 , 'Bad profile key: %r' % key ) return result
De-serialize user profile fields into concrete model fields.
De - serialize user profile fields into concrete model fields .