From e06d2c206892b0d5fec7260defc6fb078e2ec29b Mon Sep 17 00:00:00 2001 From: justme1968 Date: Sun, 21 Dec 2014 21:37:32 +0000 Subject: [PATCH] 34_SWAP.pm: autosave changed ProductCode attribute if autosave ist active git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@7300 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/34_SWAP.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/fhem/FHEM/34_SWAP.pm b/fhem/FHEM/34_SWAP.pm index 4a5855006..771ed81b0 100755 --- a/fhem/FHEM/34_SWAP.pm +++ b/fhem/FHEM/34_SWAP.pm @@ -989,6 +989,7 @@ SWAP_Parse($$) my $first = !defined($rhash->{"SWAP_00-ProductCode"}) || $rhash->{"SWAP_00-ProductCode"} ne $productcode; SWAP_Attr( "set", $rname, "ProductCode", $productcode ) if( $first ); + CommandSave(undef,undef) if( $first && AttrVal( "autocreate", "autosave", 1 ) ); if( !defined($products->{$productcode}->{registers}) ){ SWAP_readDeviceXML( $rhash, $productcode );