r9228: cleanup and simplify the AJAJ code - part 2