client/state/receipts/reducer.js
function updateReceiptState( state, receiptId, attributes ) {
	return Object.assign( {}, state, {
		[ receiptId ]: Object.assign( {}, initialReceiptState, state[ receiptId ], attributes ),
	} );
}
function updateReceiptState( state, receiptId, attributes ) {
	return Object.assign( {}, state, {
		[ receiptId ]: Object.assign( {}, initialReceiptState, state[ receiptId ], attributes ),
	} );
}
Returns a new state with the given attributes for the given receipt ID.

@param {Object} state current state
@param {Number} receiptId identifier of the site
@param {Object} attributes list of attributes and their values
@returns {Object} the new state