From: APTX Date: Sat, 27 Apr 2013 15:46:36 +0000 (+0200) Subject: Use the data from the sent command rather than the config. X-Git-Url: https://gitweb.tyo.aptx.org/?a=commitdiff_plain;h=e0c9c5588e99169f8a03b72f2f3fe5a3c4a3d6ae;p=localmylist.git Use the data from the sent command rather than the config. The config might change from what has been used with the command. --- diff --git a/localmylist/requesthandler.cpp b/localmylist/requesthandler.cpp index c296f36..a2b2b08 100644 --- a/localmylist/requesthandler.cpp +++ b/localmylist/requesthandler.cpp @@ -552,13 +552,13 @@ void RequestHandler::myListAddReplyRecieved(bool success) f.entryUpdate = QDateTime::currentDateTime(); f.myUpdate = QDateTime::currentDateTime(); - if (MyList::instance()->settings()->get("myListDefaultViewed", false)) + if (reply->command().viewed() == MyListState::Viewed) f.myWatched = QDateTime::currentDateTime(); - f.myState = State(MyList::instance()->settings()->get("myListDefaultState", 1)); - f.mySource = MyList::instance()->settings()->get("myListDefaultSource", QString()); - f.myStorage = MyList::instance()->settings()->get("myListDefaultStorage", QString()); - f.myOther = MyList::instance()->settings()->get("myListDefaultOther", QString()); + f.myState = reply->command().state(); + f.mySource = reply->command().state(); + f.myStorage = reply->command().storage(); + f.myOther = reply->command().other(); db->setFile(f); }