updated getcounts to use server instead of array_op
first working version for andor3