liquid_feedback_frontend
annotate app/main/_postfork/10_database.lua @ 1208:24f4c23f76ff
Moved code from draft add action to Draft model
| author | bsw |
|---|---|
| date | Sat Jul 18 15:58:39 2015 +0200 (2015-07-18) |
| parents | 911253ad0898 |
| children |
| rev | line source |
|---|---|
| bsw@1145 | 1 -- open and set default database handle |
| bsw@1145 | 2 _G.db = assert(mondelefant.connect(config.database)) |
| bsw@1145 | 3 |
| bsw@1145 | 4 function mondelefant.class_prototype:get_db_conn() return db end |
| bsw@1145 | 5 |
| bsw@1145 | 6 execute.inner() |
| bsw@1145 | 7 |
| bsw@1145 | 8 -- close the database |
| bsw@1145 | 9 db:close() |