def by_reference(psp_reference)
      code = Spree::Store.
        joins(orders: :payments).
        find_by(spree_payments: { response_code: psp_reference }).
        try!(:code)

      by_store_code(code)
    end
def by_reference(psp_reference)
      code = Spree::Store.
        joins(orders: :payments).
        find_by(spree_payments: { response_code: psp_reference }).
        try!(:code)

      by_store_code(code)
    end
Creates a new merchant account locator.

 @param store_account_map [Hash] a hash mapping store codes to merchant accounts
 @param default_account [String] the default merchant account to use
 Tries to find a store that has a payment with the given psp reference. If
 one exists, returns the merchant account for that store. Otherwise, returns
 the default merchant acount.

 @param psp_reference [String] the psp reference for the payment
 @return merchant account [String] the name of the merchant account