Inverted conditions for gnc_search_bill_on_id / gnc_search_invoice_on_id. g_ascii_strcasecmp returns 0 when arguments are equal.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21249 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Geert Janssens 2011-09-11 14:24:13 +00:00
parent f1e7aa4c03
commit f279678958

View File

@ -559,9 +559,9 @@ gnc_bi_import_create_bis (GtkListStore * store, QofBook * book,
// no predefined invoice number is a new invoice that's in need of a new number.
// This was not designed to satisfy the need for repeat invoices however, so maybe we need a another method for this, after all
// It should be easier to copy an invoice with a new ID than to go through all this malarky.
if (g_ascii_strcasecmp (type, "BILL"))
if (g_ascii_strcasecmp (type, "BILL") == 0)
invoice = gnc_search_bill_on_id (book, id);
else if (g_ascii_strcasecmp (type, "INVOICE"))
else if (g_ascii_strcasecmp (type, "INVOICE") == 0)
invoice = gnc_search_invoice_on_id (book, id);
if (!invoice)