Provided a code fix for Issue #3 (Boundary issue with the RepeatDirective)

I have provided a code fix(4a06211d83) for this issue.The fix includes a unit test that was failing before my fix. After the fix the unit test runs successfully. Please review and let me know what you think.