@@ -1973,23 +1973,6 @@ protected function processInboundDataNode(ProtocolNode $node, $autoReceipt = tru
1973
1973
$ this ->sendMessageReceived ($ node );
1974
1974
}
1975
1975
}
1976
- if ($ node ->hasChild ('notification ' ) && $ node ->getChild ('notification ' )->getAttribute ('type ' ) == 'picture ' ) {
1977
- if ($ node ->getChild ('notification ' )->hasChild ('set ' )) {
1978
- $ this ->eventManager ()->fireProfilePictureChanged (
1979
- $ this ->phoneNumber ,
1980
- $ node ->getAttribute ('from ' ),
1981
- $ node ->getAttribute ('id ' ),
1982
- $ node ->getAttribute ('t ' )
1983
- );
1984
- } else if ($ node ->getChild ('notification ' )->hasChild ('delete ' )) {
1985
- $ this ->eventManager ()->fireProfilePictureDeleted (
1986
- $ this ->phoneNumber ,
1987
- $ node ->getAttribute ('from ' ),
1988
- $ node ->getAttribute ('id ' ),
1989
- $ node ->getAttribute ('t ' )
1990
- );
1991
- }
1992
- }
1993
1976
if ($ node ->getAttribute ("type " ) == "media " && $ node ->getChild ('media ' ) != null ) {
1994
1977
if ($ node ->getChild ("media " )->getAttribute ('type ' ) == 'image ' ) {
1995
1978
$ this ->eventManager ()->fireGetImage (
@@ -2354,6 +2337,21 @@ protected function processInboundDataNode(ProtocolNode $node, $autoReceipt = tru
2354
2337
$ node ->getChild (0 )->getData ()); //status message
2355
2338
break ;
2356
2339
case "picture " :
2340
+ if ($ node ->hasChild ('set ' )) {
2341
+ $ this ->eventManager ()->fireProfilePictureChanged (
2342
+ $ this ->phoneNumber ,
2343
+ $ node ->getAttribute ('from ' ),
2344
+ $ node ->getAttribute ('id ' ),
2345
+ $ node ->getAttribute ('t ' )
2346
+ );
2347
+ } else if ($ node ->hasChild ('delete ' )) {
2348
+ $ this ->eventManager ()->fireProfilePictureDeleted (
2349
+ $ this ->phoneNumber ,
2350
+ $ node ->getAttribute ('from ' ),
2351
+ $ node ->getAttribute ('id ' ),
2352
+ $ node ->getAttribute ('t ' )
2353
+ );
2354
+ }
2357
2355
//TODO
2358
2356
break ;
2359
2357
case "contacts " :
0 commit comments