fix bug not to run correctly on 1.9.3/2.0.0
extract method definition