branch: externals/compat
commit c0cc3ba86b2bb3b217cb1dacf80e96fca8d7dc8e
Author: Daniel Mendler <[email protected]>
Commit: Daniel Mendler <[email protected]>

    Use string-remove-prefix
---
 compat-28.el | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/compat-28.el b/compat-28.el
index 4ab40da69b..b60720c4cc 100644
--- a/compat-28.el
+++ b/compat-28.el
@@ -591,9 +591,7 @@ Errors if the FILENAME or EXTENSION are empty, or if the 
given
 FILENAME has the format of a directory.
 
 See also `file-name-sans-extension'."
-  (let ((extn (if (string-prefix-p "." extension)
-                  (substring extension 1)
-                extension)))
+  (let ((extn (string-remove-prefix "." extension)))
     (cond
      ((string= filename "")
       (error "Empty filename"))

Reply via email to