Skip to content

Commit

Permalink
FIX Avoid infinite recursive loop with attributes in schemadata
Browse files Browse the repository at this point in the history
  • Loading branch information
GuySartorelli committed Nov 15, 2024
1 parent 9fad212 commit 34b14da
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions code/Forms/UploadField.php
Original file line number Diff line number Diff line change
Expand Up @@ -288,8 +288,6 @@ public function getAttributes()
'type' => 'file',
'multiple' => $this->getIsMultiUpload(),
'id' => $this->ID(),
'data-schema' => json_encode($this->getSchemaData()),
'data-state' => json_encode($this->getSchemaState()),
);

$attributes = array_merge($attributes, $this->attributes);
Expand Down
2 changes: 1 addition & 1 deletion templates/SilverStripe/AssetAdmin/Forms/UploadField.ss
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
</div>
<% end_if %>
</div>
<input $AttributesHTML <% include SilverStripe/Forms/AriaAttributes %> />
<input $AttributesHTML <% include SilverStripe/Forms/AriaAttributes %> data-schema="$SchemaData.JSON" data-state="$SchemaState.JSON" />

0 comments on commit 34b14da

Please sign in to comment.