Activemerchant and UK Maestro (formerly Switch) problem


I am having problem with users reporting malfunctioning of UK Maestro
cards functionality on website of a client. I am using most recent
Activemerchant library from github, which I managed to make work with
rails 1.2.

Reported error is:

Credit card invalid: start_month is invalid issue_number cannot be

In my code I made special case for UK Maestro:

       credit_card =
           :type => params[:payment][:card_type],
           :number => params[:payment][:card_number],
           :month => params[:payment][:card_valid_ex_month],
           :year => params[:payment][:card_valid_ex_year],
           :first_name => @join_request.first_name,
           :last_name => @join_request.last_name,
           :verification_value => params[:payment][:security_number]

     start_month = params[:payment][:card_valid_from_month]
     start_year = params[:payment][:card_valid_from_year]
     issue_number = params[:payment][:issue_number]

     if params[:payment][:card_type] == "switch"
       credit_card.start_month = start_month if start_month and
start_month != ""
       credit_card.start_year = start_year if start_year and
start_year !=""
       credit_card.issue_number = issue_number if issue_number and
issue_number != ""

     ... do rest of processing ...

I am using:
Rails 1.2 + patched activesupport to work with activemerchant
Activemerchant 1.3.2

Please for any suggestion on what I am doing wrong or piece of code
that is proven to work with old UK Maestro/Switch cards.