Change result conditions with hash kye value and return true and false instead of 0 and 1