summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2013-09-08 19:22:33 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2013-09-08 19:22:33 +0000
commitf90c2d591aec8d0f7c4c41b420a3e1b54fc082de (patch)
tree0e4f5c1a2e7b8a8931fabcb73fe85106788a57b3 /plugins
parent58a252dd51d4a289ecad6733aab4712212f78186 (diff)
- WhenWasIt: reordering birthday validation check - (patch from person)
git-svn-id: http://svn.miranda-ng.org/main/trunk@6025 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/WhenWasIt/src/date_utils.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/WhenWasIt/src/date_utils.cpp b/plugins/WhenWasIt/src/date_utils.cpp
index a903a36a28..6c510da4ae 100644
--- a/plugins/WhenWasIt/src/date_utils.cpp
+++ b/plugins/WhenWasIt/src/date_utils.cpp
@@ -41,12 +41,6 @@ int GetContactDOB(HANDLE hContact, int &year, int &month, int &day)
if ( IsDOBValid(year, month, day))
return DOB_USERINFO;
- year = db_get_w(hContact, "mBirthday", "BirthYear", 0);
- month = db_get_b(hContact, "mBirthday", "BirthMonth", 0);
- day = db_get_b(hContact, "mBirthday", "BirthDay", 0);
- if ( IsDOBValid(year, month, day))
- return DOB_MBIRTHDAY;
-
char *szProto = GetContactProto(hContact);
year = db_get_w(hContact, szProto, "BirthYear", 0);
month = db_get_b(hContact, szProto, "BirthMonth", 0);
@@ -60,6 +54,12 @@ int GetContactDOB(HANDLE hContact, int &year, int &month, int &day)
if ( IsDOBValid(year, month, day))
return DOB_BIRTHDAYREMINDER;
+ year = db_get_w(hContact, "mBirthday", "BirthYear", 0);
+ month = db_get_b(hContact, "mBirthday", "BirthMonth", 0);
+ day = db_get_b(hContact, "mBirthday", "BirthDay", 0);
+ if ( IsDOBValid(year, month, day))
+ return DOB_MBIRTHDAY;
+
year = db_get_dw(hContact, "micqBirthday", "BirthYear", 0);
month = db_get_dw(hContact, "micqBirthday", "BirthMonth", 0);
day = db_get_dw(hContact, "micqBirthday", "BirthDay", 0);