瀏覽代碼

Force GETS on posts

George Baugh 2 年之前
父節點
當前提交
8edcbf26f1
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      lib/Trog/Routes/HTML.pm

+ 3 - 0
lib/Trog/Routes/HTML.pm

@@ -755,6 +755,9 @@ sub post_save ($query) {
     # Ensure there are no null tags
     @{ $query->{tags} } = grep { defined $_ } @{ $query->{tags} };
 
+    # Posts will always be GET
+    $query->{method} = 'GET';
+
     $data->add($query) and die "Could not add post";
     return see_also($to);
 }