mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-09 05:24:44 +01:00
fix so success detected from new API
This commit is contained in:
parent
cd777f3b9c
commit
79d03307ad
1 changed files with 3 additions and 3 deletions
|
@ -166,9 +166,9 @@ def notifyViaFCM( devids, typ, target ):
|
|||
response = urllib2.urlopen( req ).read()
|
||||
asJson = json.loads( response )
|
||||
|
||||
if 'success' in asJson and 'failure' in asJson and len(devids) == asJson['success'] \
|
||||
and 0 == asJson['failure']:
|
||||
print "OK; no failures"
|
||||
# not sure what the response format looks like to test for success....
|
||||
if 'name' in asJson: # and len(asJson['name']) == len(devids):
|
||||
print "OK; no failures: ", response
|
||||
success = True
|
||||
else:
|
||||
print "Errors: "
|
||||
|
|
Loading…
Reference in a new issue