Browse Source

fix JSON request to always send arrays

pull/82/head
Aaron Parecki 8 years ago
parent
commit
965263492a
No known key found for this signature in database GPG Key ID: 276C2817346D6056
  1. 6
      views/new-post.php

6
views/new-post.php

@ -700,6 +700,12 @@ $(function(){
}
request.send(formData);
} else {
// Convert all single-value properties to arrays
for(var k in entry) {
if(typeof entry[k] == "string") {
entry[k] = [entry[k]];
}
}
$.post("/micropub/postjson", {
data: JSON.stringify({
"type": ["h-entry"],

Loading…
Cancel
Save