throw error if exceeds opts.maxLoop, fixes #3