Deploying to gh-pages from @ e9e6aac770 🚀

This commit is contained in:
realaravinth
2021-07-21 16:56:56 +00:00
parent 736317658d
commit d0a1027cea
67 changed files with 681 additions and 80 deletions

View File

@@ -108,22 +108,24 @@
<span id="105">105</span>
<span id="106">106</span>
<span id="107">107</span>
<span id="108">108</span>
<span id="109">109</span>
</pre><div class="example-wrap"><pre class="rust ">
<span class="comment">/*
* Copyright (C) 2021 Aravinth Manivannan &lt;realaravinth@batsense.net&gt;
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License along with this program. If not, see &lt;https://www.gnu.org/licenses/&gt;.
*/</span>
* Copyright (C) 2021 Aravinth Manivannan &lt;realaravinth@batsense.net&gt;
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License along with this program. If not, see &lt;https://www.gnu.org/licenses/&gt;.
*/</span>
<span class="kw">use</span> <span class="ident">actix_web::web::ServiceConfig</span>;
@@ -131,6 +133,7 @@
<span class="kw">pub</span> <span class="kw">mod</span> <span class="ident">errors</span>;
<span class="kw">mod</span> <span class="ident">panel</span>;
<span class="kw">pub</span> <span class="kw">mod</span> <span class="ident">routes</span>;
<span class="kw">mod</span> <span class="ident">sitemap</span>;
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">NAME</span>: <span class="kw-2">&amp;</span><span class="ident">str</span> <span class="op">=</span> <span class="string">&quot;mCaptcha&quot;</span>;
@@ -138,6 +141,7 @@
<span class="ident">auth::services</span>(<span class="ident">cfg</span>);
<span class="ident">panel::services</span>(<span class="ident">cfg</span>);
<span class="ident">errors::services</span>(<span class="ident">cfg</span>);
<span class="ident">cfg</span>.<span class="ident">service</span>(<span class="ident">sitemap::sitemap</span>);
}
<span class="attribute">#[<span class="ident">cfg</span>(<span class="ident">not</span>(<span class="ident">tarpaulin_include</span>))]</span>
@@ -205,7 +209,7 @@
<span class="attribute">#[<span class="ident">actix_rt::test</span>]</span>
<span class="kw">async</span> <span class="kw">fn</span> <span class="ident">public_pages_tempaltes_work</span>() {
<span class="kw">let</span> <span class="ident">app</span> <span class="op">=</span> <span class="ident">test::init_service</span>(<span class="ident">App::new</span>().<span class="ident">configure</span>(<span class="ident">services</span>)).<span class="kw">await</span>;
<span class="kw">let</span> <span class="ident">urls</span> <span class="op">=</span> <span class="macro">vec!</span>[<span class="ident">PAGES</span>.<span class="ident">auth</span>.<span class="ident">login</span>, <span class="ident">PAGES</span>.<span class="ident">auth</span>.<span class="ident">join</span>];
<span class="kw">let</span> <span class="ident">urls</span> <span class="op">=</span> <span class="macro">vec!</span>[<span class="ident">PAGES</span>.<span class="ident">auth</span>.<span class="ident">login</span>, <span class="ident">PAGES</span>.<span class="ident">auth</span>.<span class="ident">join</span>, <span class="ident">PAGES</span>.<span class="ident">sitemap</span>];
<span class="kw">for</span> <span class="ident">url</span> <span class="kw">in</span> <span class="ident">urls</span>.<span class="ident">iter</span>() {
<span class="kw">let</span> <span class="ident">resp</span> <span class="op">=</span>