branch: externals/standard-themes
commit be08ec7320ba3435c7538d648ebbb963d8912ba4
Author: Protesilaos Stavrou <i...@protesilaos.com>
Commit: Protesilaos Stavrou <i...@protesilaos.com>

    Use our helper function instead of a lambda for string-prefix-p
---
 standard-themes.el | 18 ++++++------------
 1 file changed, 6 insertions(+), 12 deletions(-)

diff --git a/standard-themes.el b/standard-themes.el
index 5d6fb0f235..17a7635fe9 100644
--- a/standard-themes.el
+++ b/standard-themes.el
@@ -515,12 +515,13 @@ symbol, which is safe when used as a face attribute's 
value."
       value
     'unspecified))
 
+(defun standard-themes--standard-p (theme)
+  "Return non-nil if THEME name has a standard- prefix."
+  (string-prefix-p "standard-" (symbol-name theme)))
+
 (defun standard-themes--list-enabled-themes ()
   "Return list of `custom-enabled-themes' with standard- prefix."
-  (seq-filter
-   (lambda (theme)
-     (string-prefix-p "standard-" (symbol-name theme)))
-   custom-enabled-themes))
+  (seq-filter #'standard-themes--standard-p custom-enabled-themes))
 
 (defun standard-themes--enable-themes ()
   "Enable the Standard themes."
@@ -532,10 +533,7 @@ symbol, which is safe when used as a face attribute's 
value."
 (defun standard-themes--list-known-themes ()
   "Return list of `custom-known-themes' with standard- prefix."
   (standard-themes--enable-themes)
-  (seq-filter
-   (lambda (theme)
-     (string-prefix-p "standard-" (symbol-name theme)))
-   custom-known-themes))
+  (seq-filter #'standard-themes--standard-p custom-known-themes))
 
 (defun standard-themes--current-theme ()
   "Return first enabled Standard theme."
@@ -580,10 +578,6 @@ overrides."
             (propertize (car (split-string doc-string "\\."))
                         'face 'completions-annotations))))
 
-(defun standard-themes--standard-p (theme)
-  "Return non-nil if THEME name has a standard- prefix."
-  (string-prefix-p "standard-" (symbol-name theme)))
-
 (defvar standard-themes--select-theme-history nil
   "Minibuffer history of `standard-themes--select-prompt'.")
 

Reply via email to