liquid_feedback_frontend
diff app/main/draft/_action/add.lua @ 4:80c215dbf076
Version alpha5
Many optical changes and improved usability
Support for different wiki-formatting-engines
Help system
Many optical changes and improved usability
Support for different wiki-formatting-engines
Help system
author | bsw/jbe |
---|---|
date | Thu Dec 10 12:00:00 2009 +0100 (2009-12-10) |
parents | 3bfb2fcf7ab9 |
children | afd9f769c7ae |
line diff
1.1 --- a/app/main/draft/_action/add.lua Mon Nov 30 12:00:00 2009 +0100 1.2 +++ b/app/main/draft/_action/add.lua Thu Dec 10 12:00:00 2009 +0100 1.3 @@ -4,6 +4,17 @@ 1.4 local draft = Draft:new() 1.5 draft.author_id = app.session.member.id 1.6 draft.initiative_id = initiative.id 1.7 + local formatting_engine = param.get("formatting_engine") 1.8 + local formatting_engine_valid = false 1.9 + for fe, dummy in pairs(config.formatting_engine_executeables) do 1.10 + if formatting_engine == fe then 1.11 + formatting_engine_valid = true 1.12 + end 1.13 + end 1.14 + if not formatting_engine_valid then 1.15 + error("invalid formatting engine!") 1.16 + end 1.17 + draft.formatting_engine = formatting_engine 1.18 draft.content = param.get("content") 1.19 draft:save() 1.20