32_yowsup.pm: added sent reading

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@8802 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
justme1968
2015-06-22 19:20:36 +00:00
parent 4eee239dd2
commit 36e293786d

View File

@@ -246,6 +246,8 @@ yowsup_Set($$@)
} elsif( $cmd eq 'send' ) { } elsif( $cmd eq 'send' ) {
return "MASTER not connected" if( !$phash->{PID} ); return "MASTER not connected" if( !$phash->{PID} );
readingsSingleUpdate( $hash, "sent", join( ' ', @args ), 1 );
return yowsup_Write( $phash, "/message send $hash->{NUMBER} '". join( ' ', @args ) ."'" ); return yowsup_Write( $phash, "/message send $hash->{NUMBER} '". join( ' ', @args ) ."'" );
return undef; return undef;
@@ -266,6 +268,8 @@ yowsup_Set($$@)
return undef; return undef;
} elsif( $cmd eq 'send' ) { } elsif( $cmd eq 'send' ) {
readingsSingleUpdate( $hash, "sent", join( ' ', @args ), 1 );
return yowsup_Write( $hash, "/message send ". shift(@args) ." '". join( ' ', @args ) ."'" ); return yowsup_Write( $hash, "/message send ". shift(@args) ." '". join( ' ', @args ) ."'" );
return undef; return undef;