]> git.donarmstrong.com Git - biopieces.git/blobdiff - code_ruby/lib/maasha/fastq.rb
finished refactoring s/has_key?/[]/
[biopieces.git] / code_ruby / lib / maasha / fastq.rb
index c57f4eb9165bb3423fccc22590f89550a8125c69..4ac44aa70cb84045158fc775f782be7719fdbbbd 100644 (file)
@@ -83,7 +83,7 @@ class FastqIndex
   # Method to read from file a Fastq entry from an indexed position,
   # and return the entry as a Seq object.
   def get(seq_name)
-    raise FastqError, "Sequence name: #{seq_name} not found in index." unless @index.has_key? seq_name
+    raise FastqError, "Sequence name: #{seq_name} not found in index." unless @index[seq_name]
 
     elem = @index[seq_name]
     @ios.sysseek(elem.offset_seq)