emacs-easy-hugo icon indicating copy to clipboard operation
emacs-easy-hugo copied to clipboard

I can't move to next blog when there is only 1 blog in easy-hugo-bloglist.

Open xyslope opened this issue 1 year ago • 1 comments

Hi, I am using easy hugo for some years. I really like it.

The follwing code will do nothing when there is only 1 blog in easy-hugo-bloglist. (defun easy-hugo-next-blog () "Go to next blog." (when (< 1 (length easy-hugo-bloglist)) (if (eq (- (length easy-hugo-bloglist) 1) easy-hugo--current-blog) (setq easy-hugo--current-blog 0)

In that case, (length easy-hugo-bloglist) return 1 and exit the function.

Should it be either of the following code?

(boundp 'easy-hugo-bloglist) or (when (< 0 (length easy-hugo-bloglist))

Well, I am trying to fix this issue but haven't got good solution.

xyslope avatar Feb 28 '24 07:02 xyslope

Hi, @xyslope ! Thank you for comment. I don't understand the situation, so could you show me the part of your init.el related to easy-hugo?

masasam avatar Feb 28 '24 08:02 masasam

I am really sorry. I can't remember what I wanted to say at that time. I will examine source codes later and make an new issue.

Thank you.

xyslope avatar Apr 25 '24 07:04 xyslope