You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
writeJSONError(w, http.StatusUnprocessableEntity, fmt.Sprintf("no companyContract template found for event %d and language %s", eventID, lowerLang))
159
+
return
160
+
}
161
+
iflen(candidates) >1 {
162
+
writeJSONError(w, http.StatusConflict, fmt.Sprintf("multiple companyContract templates found for event %d and language %s; expected exactly one", eventID, lowerLang))
136
163
return
137
164
}
138
-
// use the single template
139
-
ifeventTemplates[0].Url=="" {
165
+
166
+
// use the single matching template
167
+
ifcandidates[0].Url=="" {
140
168
writeJSONError(w, http.StatusUnprocessableEntity, "template has no URL")
0 commit comments