From e79e21b4107272662d008ba5e06881a772f81032 Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Sun, 14 Feb 2021 18:42:10 -0800 Subject: [PATCH] Only try to change the company backends when company-capf is found --- oni-company.el | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/oni-company.el b/oni-company.el index 53ff9fb..cfa8cf0 100644 --- a/oni-company.el +++ b/oni-company.el @@ -4,7 +4,7 @@ ;; Author: Tom Willemse ;; Keywords: local -;; Version: 2020.0408.110439 +;; Version: 2021.0214.181156 ;; Package-Requires: (company oni-prescient company-posframe diminish company-prescient) ;; This program is free software; you can redistribute it and/or modify @@ -51,8 +51,9 @@ company-echo-metadata-frontend company-preview-frontend)) -(setf (car (member 'company-capf company-backends)) - '(company-capf :with company-yasnippet)) +(when (member 'company-capf company-backends) + (setf (car (member 'company-capf company-backends)) + '(company-capf :with company-yasnippet))) (add-hook 'company-completion-started-hook 'oni-company--enable-posframe)