I have come across a problem when trying to modify the plain text content of a record after it has been converted.
Here is an illustrative script:
tell application id "DNtp"
set theRecord to get record with uuid "[uuid]" -- markdown file containing "abcdefg"
set convertedRecord to convert record theRecord to markdown in current group
set plain text of theRecord to "x"
-- result: plain text is "x"
set plain text of convertedRecord to "x"
-- result: plain text is "abcdefg"
end tell
(The reason why I’m doing this is because convert
consolidates transcluded markdown files into a single document.)
As you can see, the record created by the convert
command refuses to modify its plain text field. Exactly the same thing seems to happen when using simple plain text (rather than markdown) files.
Is this a bug or am I missing something?