fix js errors

This commit is contained in:
Alex Turchyn authored and Pete Matsyburka committed 2024-05-31 13:08:02 +03:00
1 parent c56f8cb38f
commit 7080e8ea33
4 files changed
+31 -17

No files matched your search

@@ -4,7 +4,9 @@ class TemplateDocumentsController < ApplicationController
load_and_authorize_resource :template
def create
return head :unprocessable_entity if params[:blobs].blank? && params[:files].blank?
if params[:blobs].blank? && params[:files].blank?
return render json: { error: 'File is missing' }, status: :unprocessable_entity
end
old_fields_hash = @template.fields.hash