Debugging tags reformating.
This commit is contained in:
parent
a0aabc55f0
commit
4fab465883
@ -594,18 +594,25 @@ Tiddler >> tagsAsString [
|
||||
^ response contents
|
||||
]
|
||||
|
||||
{ #category : #accessing }
|
||||
Tiddler >> tagsInBrackets [
|
||||
| tagsInBrackets |
|
||||
tagsInBrackets := self rawLinksIn: self tags.
|
||||
^ tagsInBrackets
|
||||
]
|
||||
|
||||
{ #category : #accessing }
|
||||
Tiddler >> tagsReformating [
|
||||
| response sanitized tagsInBrackets |
|
||||
| response sanitized |
|
||||
self tags class ~= ByteString ifTrue: [ ^ self ].
|
||||
response := Set new.
|
||||
tagsInBrackets := self rawLinksIn: self tags.
|
||||
tagsInBrackets ifNotEmpty: [
|
||||
tagsInBrackets do: [:tag | sanitized := self tags copyReplaceAll: tag with: ''. ]
|
||||
sanitized := self tags.
|
||||
self tagsInBrackets ifNotEmpty: [
|
||||
self tagsInBrackets do: [:tag | sanitized := sanitized copyReplaceAll: tag with: ''. ].
|
||||
sanitized := sanitized copyReplaceAll: '[[]] ' with: ''.
|
||||
].
|
||||
sanitized := sanitized copyReplaceAll: '[[]] ' with: ''.
|
||||
response addAll: (sanitized trimmed splitOn: Character space) asSet.
|
||||
self tags: (response union: tagsInBrackets).
|
||||
self tags: (response union: self tagsInBrackets).
|
||||
|
||||
]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user