# HG changeset patch # User bsw # Date 1324243180 -3600 # Node ID e2b8f9dcc4a642eba2fbf57e6d5a3f1eddc53d35 # Parent 6a830c1479b0ead0f8adf63c98f1a502f7c52489 Bug fix in ui.form related to file upload diff -r 6a830c1479b0 -r e2b8f9dcc4a6 framework/env/ui/form.lua --- a/framework/env/ui/form.lua Sun Dec 18 22:14:03 2011 +0100 +++ b/framework/env/ui/form.lua Sun Dec 18 22:19:40 2011 +0100 @@ -84,7 +84,7 @@ prepare_routing_params(params, args.routing, args.module) params._webmcp_csrf_secret = request.get_csrf_secret() local attr = table.new(args.attr) - if attr.enctype=="multipart/form-data" or slot_state.form_file_upload then + if attr.enctype=="multipart/form-data" or args.file_upload then slot_state.form_file_upload = true if attr.enctype == nil then attr.enctype = "multipart/form-data"