[fix] #14, loop boundary was set to SECTION.length instead of 3, other minor stuff