moved all session-related settings to the database
using "yoda" conditions