fixed @messages not being defined in case of valid search
Merge branch 'bugfix/@messages-in-case-of-valid-search' into develop