Updated to remove excess hashes and arrays that weren't needed and changed book IDing method