Skip to content

Commit

Permalink
get rid of compiler warnings related to goog.labs.userAgent.browser
Browse files Browse the repository at this point in the history
  • Loading branch information
darwin committed Mar 2, 2022
1 parent 46177e5 commit f854458
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/lib/devtools/async.cljs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
(ns devtools.async
(:require-macros [devtools.oops :refer [oset ocall]])
(:require [goog.async.nextTick]
[goog.labs.userAgent.browser :as ua]
[goog.labs.userAgent.browser :refer [isChrome isVersionOrHigher]]
[devtools.context :as context]))

(defn ^:dynamic available? []
Expand All @@ -10,7 +10,7 @@
(def ^:dynamic fixed-chrome-version-for-async "65.0.3321")

(defn ^:dynamic needed? []
(not (and (ua/isChrome) (ua/isVersionOrHigher fixed-chrome-version-for-async))))
(not (and (isChrome) (isVersionOrHigher fixed-chrome-version-for-async))))

(defn ^:dynamic get-not-needed-message []
(str "cljs-devtools: the :async feature is no longer needed since Chrome " fixed-chrome-version-for-async ", "
Expand Down
4 changes: 2 additions & 2 deletions src/lib/devtools/formatters.cljs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(ns devtools.formatters
(:require-macros [devtools.oops :refer [unchecked-aget unchecked-aset]])
(:require [goog.labs.userAgent.browser :as ua]
(:require [goog.labs.userAgent.browser :refer [isChrome isVersionOrHigher]]
[devtools.prefs :as prefs]
[devtools.util :refer [get-formatters-safe set-formatters-safe! in-node-context?]]
[devtools.context :as context]
Expand All @@ -14,7 +14,7 @@

(defn ^:dynamic available? []
(or (in-node-context?) ; node.js or Chrome 47+
(and (ua/isChrome) (ua/isVersionOrHigher 47))))
(and (isChrome) (isVersionOrHigher 47))))

(deftype CLJSDevtoolsFormatter [])

Expand Down

0 comments on commit f854458

Please sign in to comment.