Add precondition for 'el-get-insecure-check

When URL parameter is nil, fail fast with explicit reason instead of
throwing wrong-type-argument later on.
This commit is contained in:
Mykola Nikishov 2016-09-17 16:56:47 +03:00
parent 63be589c1d
commit 28946c386e

View File

@ -39,6 +39,7 @@ following is true and retun nil:
SCP-like syntax
- PACKAGE definition has a non-empty :checksum"
(assert (stringp URL) nil "URL is nil, can't decide if it's safe to install package '%s'" PACKAGE)
(let* ((checksum (plist-get (el-get-package-def PACKAGE) :checksum))
(checksum-empty (or (not (stringp checksum))
(if (fboundp 'string-blank-p)