Fixed database scoping and initial loading

added libraryId to series