diff options
Diffstat (limited to 'src/session.cc')
-rw-r--r-- | src/session.cc | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/src/session.cc b/src/session.cc index bbc196df..2ae09e21 100644 --- a/src/session.cc +++ b/src/session.cc @@ -71,9 +71,9 @@ session_t::session_t() TRACE_CTOR(session_t, ""); if (const char * home_var = std::getenv("HOME")) - HANDLER(price_db_).on((path(home_var) / ".pricedb").string()); + HANDLER(price_db_).on(none, (path(home_var) / ".pricedb").string()); else - HANDLER(price_db_).on(path("./.pricedb").string()); + HANDLER(price_db_).on(none, path("./.pricedb").string()); // Add time commodity conversions, so that timelog's may be parsed // in terms of seconds, but reported as minutes or hours. @@ -245,27 +245,12 @@ expr_t::ptr_op_t session_t::lookup(const string& name) { const char * p = name.c_str(); switch (*p) { - case 'd': - if (is_eq(p, "date")) - return MAKE_FUNCTOR(session_t::fn_today); - break; - - case 'n': - if (is_eq(p, "now")) - return MAKE_FUNCTOR(session_t::fn_now); - break; - case 'o': if (WANT_OPT()) { p += OPT_PREFIX_LEN; if (option_t<session_t> * handler = lookup_option(p)) return MAKE_OPT_HANDLER(session_t, handler); } break; - - case 't': - if (is_eq(p, "today")) - return MAKE_FUNCTOR(session_t::fn_today); - break; } // Check if they are trying to access an option's setting or value. |