Skip to content

Commit 6083c74

Browse files
committed
Avoid false positives.
1 parent 5b0c2b0 commit 6083c74

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sphinxlint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@
113113
# .. versionchanged: 3.6
114114
# as it should be:
115115
# .. versionchanged:: 3.6
116-
seems_directive_re = re.compile(rf"(?<!\.)\.\. {all_directives}([^a-z:]|:(?!:))")
116+
seems_directive_re = re.compile(rf"^\s*(?<!\.)\.\. {all_directives}([^a-z:]|:(?!:))")
117117

118118
# Find directive prefixed with three dots instead of two, like:
119119
# ... versionchanged:: 3.6

0 commit comments

Comments
 (0)