Skip to content

Commit aa054b3

Browse files
deploy: bf73d63
1 parent 355c4e9 commit aa054b3

File tree

15 files changed

+32
-16
lines changed

15 files changed

+32
-16
lines changed

oo7/dbus/enum.Error.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

oo7/dbus/enum.ServiceError.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

oo7/portal/enum.Error.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

oo7/struct.Key.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

search-index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/oo7/dbus/collection.rs.html

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,14 @@ <h2>Files</h2></div></nav><div class="sidebar-resizer"></div>
311311
<a href="#309" id="309">309</a>
312312
<a href="#310" id="310">310</a>
313313
<a href="#311" id="311">311</a>
314+
<a href="#312" id="312">312</a>
315+
<a href="#313" id="313">313</a>
316+
<a href="#314" id="314">314</a>
317+
<a href="#315" id="315">315</a>
318+
<a href="#316" id="316">316</a>
319+
<a href="#317" id="317">317</a>
320+
<a href="#318" id="318">318</a>
321+
<a href="#319" id="319">319</a>
314322
</pre></div><pre class="rust"><code><span class="kw">use </span>std::{collections::HashMap, sync::Arc, time::Duration};
315323

316324
<span class="attr">#[cfg(feature = <span class="string">"async-std"</span>)]
@@ -568,7 +576,7 @@ <h2>Files</h2></div></nav><div class="sidebar-resizer"></div>
568576
<span class="attr">#[cfg(feature = <span class="string">"local_tests"</span>)]
569577
</span><span class="kw">use super</span>::<span class="kw-2">*</span>;
570578
<span class="attr">#[cfg(feature = <span class="string">"local_tests"</span>)]
571-
</span><span class="kw">use </span><span class="kw">crate</span>::dbus::Service;
579+
</span><span class="kw">use </span><span class="kw">crate</span>::dbus::{<span class="self">self</span>, Service};
572580

573581
<span class="attr">#[cfg(feature = <span class="string">"local_tests"</span>)]
574582
</span><span class="kw">async fn </span>create_item(service: Service&lt;<span class="lifetime">'_</span>&gt;, encrypted: bool) {
@@ -581,7 +589,15 @@ <h2>Files</h2></div></nav><div class="sidebar-resizer"></div>
581589
attributes.insert(<span class="string">"type"</span>, value);
582590
<span class="kw">let </span>secret = <span class="string">"a password"</span>.as_bytes();
583591

584-
<span class="kw">let </span>collection = service.default_collection().<span class="kw">await</span>.unwrap();
592+
<span class="kw">let </span>collection = <span class="kw">match </span>service.default_collection().<span class="kw">await </span>{
593+
<span class="prelude-val">Err</span>(dbus::Error::NotFound(<span class="kw">_</span>)) =&gt; {
594+
service
595+
.create_collection(<span class="string">"Default"</span>, <span class="prelude-val">Some</span>(dbus::DEFAULT_COLLECTION))
596+
.<span class="kw">await
597+
</span>}
598+
e =&gt; e,
599+
}
600+
.unwrap();
585601
<span class="kw">let </span>n_items = collection.items().<span class="kw">await</span>.unwrap().len();
586602
<span class="kw">let </span>n_search_items = collection.search_items(<span class="kw-2">&amp;</span>attributes).<span class="kw">await</span>.unwrap().len();
587603

trait.impl/core/convert/trait.From.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

trait.impl/core/error/trait.Error.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)