- if (!afb_hreq_valid_tail(hreq)) {
- afb_hreq_reply_error(hreq, MHD_HTTP_FORBIDDEN);
- return 1;
+ search = locale_root_search(da->root, hreq->lang, 0);
+ rc = afb_hreq_reply_locale_file_if_exist(hreq, search, &hreq->tail[1]);
+ locale_search_unref(search);
+ if (rc == 0) {
+ if (da->relax)
+ return 0;
+ afb_hreq_reply_error(hreq, MHD_HTTP_NOT_FOUND);