Skip to content

Commit 909ac9c

Browse files
committed
Address review comments
1 parent 96c3b5a commit 909ac9c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

distributor/src/distributor/website.bal

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,9 @@ service mediaWebsite on mediaListener {
122122
return caller->ok(r.jsonResult);
123123
} else if format == "html" {
124124
http:Response hr = new;
125-
boolean sorted = (r.jsonResult.'type == RN_SI || r.jsonResult.'type == RN_V ||
126-
r.jsonResult.'type == RN_VS || r.jsonResult.'type == RN_VSN) ? true : false;
125+
string resultType = r.jsonResult.'type.toString();
126+
boolean sorted = (resultType == RN_SI || resultType == RN_V || resultType == RN_VS ||
127+
resultType == RN_VSN) ? true : false;
127128
hr.setTextPayload(<@untainted>check generateHtml(election, r.jsonResult, sorted));
128129
hr.setContentType("text/html");
129130
return caller->ok(hr);

0 commit comments

Comments
 (0)