fix(docs): Example now uses hyper_rustls

It's already done by the CLI, but the docs still showed
code that would only work in older hyper versions that still
shipped with HTTPS.

Fixes #169
This commit is contained in:
Sebastian Thiel
2017-05-26 10:14:39 +02:00
parent ad2748a691
commit 4660d23676
3 changed files with 6 additions and 2 deletions

View File

@@ -258,9 +258,9 @@ let secret: ApplicationSecret = Default::default();
// retrieve them from storage.
% endif
let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
hyper::Client::new(),
hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
<MemoryStorage as Default>::default(), None);
let mut hub = ${hub_type}::new(hyper::Client::new(), auth);\
let mut hub = ${hub_type}::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);\
</%def>
## You will still have to set the filter for your comment type - either nothing, or rust_doc_comment !