git: 22d9c0d697 - main - Fix link references in single book
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 07 Dec 2022 18:23:02 UTC
The branch main has been updated by carlavilla:
URL: https://cgit.FreeBSD.org/doc/commit/?id=22d9c0d697157330d9d6298eaf0ee27659fe30d0
commit 22d9c0d697157330d9d6298eaf0ee27659fe30d0
Author: Sergio Carlavilla Delgado <carlavilla@FreeBSD.org>
AuthorDate: 2022-12-07 18:22:10 +0000
Commit: Sergio Carlavilla Delgado <carlavilla@FreeBSD.org>
CommitDate: 2022-12-07 18:22:10 +0000
Fix link references in single book
PR: 262661
Submitted by: grahamperrin@
---
shared/lib/InterDocumentReferencesMacro/extension.rb | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/shared/lib/InterDocumentReferencesMacro/extension.rb b/shared/lib/InterDocumentReferencesMacro/extension.rb
index 76e63f4a89..455f63c002 100644
--- a/shared/lib/InterDocumentReferencesMacro/extension.rb
+++ b/shared/lib/InterDocumentReferencesMacro/extension.rb
@@ -15,14 +15,14 @@ class InterDocumentReferencesMacro < Asciidoctor::Extensions::InlineMacroProcess
doc = parent.document
- if doc.attributes['book'] == 'True'
- if doc.attributes['isonline'] == 1
+ if doc.attributes['book'] == "true"
+ if doc.attributes['isonline'] == "1"
(create_anchor parent, text, type: :link, target: %(./##{anchor})).render
else
(create_anchor parent, text, type: :link, target: %(./index.html##{anchor})).render
end
else
- if doc.attributes['isonline'] == 1
+ if doc.attributes['isonline'] == "1"
(create_anchor parent, text, type: :link, target: %(../#{destination}/##{anchor})).render
else
(create_anchor parent, text, type: :link, target: %(../#{destination}/index.html##{anchor})).render