Skip to content

Commit 0323ff6

Browse files
Additional fix for <MAXSTRING> error on big %ToJSON() calls (added write "")
1 parent 18c01de commit 0323ff6

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

Form/REST/Form.cls.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ Get available forms list as a JSON array</Description>
3333
<ReturnType>%Status</ReturnType>
3434
<Implementation><![CDATA[
3535
set forms = ##class(Form.Info).getFormsList()
36+
write ""
3637
write forms.%ToJSON()
3738
return $$$OK
3839
]]></Implementation>
@@ -45,6 +46,7 @@ Get available forms metadata as JSON object</Description>
4546
<ReturnType>%Status</ReturnType>
4647
<Implementation><![CDATA[
4748
set metadata = ##class(Form.Info).getFormsMetadata()
49+
write ""
4850
write metadata.%ToJSON()
4951
return $$$OK
5052
]]></Implementation>
@@ -58,6 +60,7 @@ Get form metainformation by name</Description>
5860
<ReturnType>%Status</ReturnType>
5961
<Implementation><![CDATA[
6062
set metadata = ##class(Form.Info).getFormMetadata(form)
63+
write ""
6164
write metadata.%ToJSON()
6265
return $$$OK
6366
]]></Implementation>

Form/REST/Main.cls.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
<Implementation><![CDATA[
4848
set info = {}
4949
set info.languages = ##class(Form.Util.Translate).getLanguages()
50+
write ""
5051
write info.%ToJSON()
5152
quit $$$OK
5253
]]></Implementation>

0 commit comments

Comments
 (0)