Fixed (partially): Documents Library Issue

Fixed the issue with displaying the wrong document however it now does
not return to where it should and has duplicate documents.