From 3da4e567026ccdd4bac06ff0b5d9e20ccdb1d6d9 Mon Sep 17 00:00:00 2001
From: "dependabot-preview[bot]"
 <27856297+dependabot-preview[bot]@users.noreply.github.com>
Date: Mon, 23 Mar 2020 11:23:50 +0100
Subject: [PATCH] Bump time from 0.1.42 to 0.2.9 (#44)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

* Bump time from 0.1.42 to 0.2.9

Bumps [time](https://github.com/time-rs/time) from 0.1.42 to 0.2.9.
- [Release notes](https://github.com/time-rs/time/releases)
- [Changelog](https://github.com/time-rs/time/blob/master/CHANGELOG.md)
- [Commits](https://github.com/time-rs/time/commits/v0.2.9)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Update to new API.

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Tomasz Drwięga <tomusdrw@gmail.com>
---
 bridges/relays/ethereum/Cargo.toml  | 2 +-
 bridges/relays/ethereum/src/main.rs | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/bridges/relays/ethereum/Cargo.toml b/bridges/relays/ethereum/Cargo.toml
index 413f16e9a09..6120710b337 100644
--- a/bridges/relays/ethereum/Cargo.toml
+++ b/bridges/relays/ethereum/Cargo.toml
@@ -20,7 +20,7 @@ rustc-hex = "2.0.1"
 serde = { version = "1.0.105", features = ["derive"] }
 serde_json = "1.0.40"
 sp-bridge-eth-poa = { path = "../../primitives/ethereum-poa" }
-time = "0.1"
+time = "0.2"
 web3 = { git = "https://github.com/svyatonik/rust-web3.git", branch = "fix_receipt" }
 
 # Substrate Based Dependencies
diff --git a/bridges/relays/ethereum/src/main.rs b/bridges/relays/ethereum/src/main.rs
index 583faf08c90..28ff6d18d94 100644
--- a/bridges/relays/ethereum/src/main.rs
+++ b/bridges/relays/ethereum/src/main.rs
@@ -66,8 +66,7 @@ fn initialize() {
 	builder.parse_filters(&filters);
 	builder.format(move |buf, record| {
 		writeln!(buf, "{}", {
-			let timestamp =
-				time::strftime("%Y-%m-%d %H:%M:%S %Z", &time::now()).expect("Time is incorrectly formatted");
+			let timestamp = time::OffsetDateTime::now_local().format("%Y-%m-%d %H:%M:%S %Z");
 			if cfg!(windows) {
 				format!("{} {} {} {}", timestamp, record.level(), record.target(), record.args())
 			} else {
-- 
GitLab