fix case sensitive checking

@devoncarew