Master reconciliation and statement import ama

i'd rewrite this in the following way; to have it more readable:

sign = 1
amount_field  = 'debit'
if  statement_currency == company_currency:
    if if st_line.amount < 0:
        amount_field = 'credit'
        sign = -1
else:
    amount_field = 'amount_currency'