<p>There's no need to expose raw field names or SQL terms in the API like that - just use <code>order=newest</code> and <code>order=oldest</code> or something.</p>
<p>Also try to avoid text interpolation into queries like that unless it's absolutely necessary - yes I know it's safe here, but I'd rather just see a conditional block that chains on the right order statement to the query for each possible sort order.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2381?email_source=notifications&email_token=AAK2OLJHXQPNIQ2PQRIFXFTQMX6BVA5CNFSM4I5CYR2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAIL64A#issuecomment-537968496">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLNW7GSNV57KKMPF3NDQMX6BVANCNFSM4I5CYR2A">mute the thread</a>.<img src="https://github.com/notifications/beacon/AAK2OLPMZBLN7T3I5ATAVRDQMX6BVA5CNFSM4I5CYR2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAIL64A.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/2381?email_source=notifications\u0026email_token=AAK2OLJHXQPNIQ2PQRIFXFTQMX6BVA5CNFSM4I5CYR2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAIL64A#issuecomment-537968496",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/2381?email_source=notifications\u0026email_token=AAK2OLJHXQPNIQ2PQRIFXFTQMX6BVA5CNFSM4I5CYR2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAIL64A#issuecomment-537968496",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>