Fixed insertion errors where insertion index is wrong
Merge pull request #13 from mattquiros/master

Fixed insertion errors where insertion index is wrong