From 3b6c9648f320d175de14e4b80df8980dcba54282 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bla=C5=BE=20Hrastnik?= <blaz@mxxn.io>
Date: Mon, 22 Feb 2021 11:43:57 +0900
Subject: [PATCH] fix clippy lint

---
 helix-view/src/document.rs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/helix-view/src/document.rs b/helix-view/src/document.rs
index dd7b14fc..426c8e21 100644
--- a/helix-view/src/document.rs
+++ b/helix-view/src/document.rs
@@ -274,7 +274,7 @@ impl Document {
     #[inline]
     /// Corresponding language scope name. Usually `source.<lang>`.
     pub fn language(&self) -> Option<&str> {
-        self.language.as_ref().map(String::as_str)
+        self.language.as_deref()
     }
 
     #[inline]