Fix bug that makes search impossible

This bug, I think made by myself in #33 :flushed:, caused a SQL error when searching.
I'am sorry, this PR fix it