backbone-dynamodb.js
function serializeAllDates(model, json) {
	_.each(json, function (value, name) {
		if ( _.isDate( value ) ) {
			json[ name ] = model.serializeDate( name, value );
		} else if ( !isScalar( value ) && !isBackboneInstance( value ) && isRecursive( value ) ) {
			serializeAllDates( model, value );
		}
	});

	return json;
}
function serializeAllDates(model, json) {
	_.each(json, function (value, name) {
		if ( _.isDate( value ) ) {
			json[ name ] = model.serializeDate( name, value );
		} else if ( !isScalar( value ) && !isBackboneInstance( value ) && isRecursive( value ) ) {
			serializeAllDates( model, value );
		}
	});

	return json;
}
function serializeAllDates ( model , json ) { _ . each ( json , function ( value , name ) { if ( _ . isDate ( value ) ) { json [ name ] = model . serializeDate ( name , value ) ; } else if ( ! isScalar ( value ) && ! isBackboneInstance ( value ) && isRecursive ( value ) ) { serializeAllDates ( model , value ) ; } } ) ; return json ; }
Recursively serializes all `Date` values in an object.

@param {Backbone.DynamoDB.Model} model
@param {Object} json
Recursively serializes all Date values in an object .