Skip to content

Commit

Permalink
[serialbutton] Removed dependency on 'org.apache.commons.io.IOUtils'
Browse files Browse the repository at this point in the history
Relative to openhab#7722

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
  • Loading branch information
lolodomo committed May 22, 2020
1 parent efc84f1 commit 593dbc1
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
import java.io.InputStream;
import java.util.TooManyListenersException;

import org.apache.commons.io.IOUtils;
import org.eclipse.jdt.annotation.NonNull;
import org.eclipse.smarthome.core.thing.ChannelUID;
import org.eclipse.smarthome.core.thing.CommonTriggerEvents;
Expand Down Expand Up @@ -93,10 +92,15 @@ public void initialize() {

@Override
public void dispose() {
if (inputStream != null) {
try {
inputStream.close();
} catch (IOException e) {
}
}
if (serialPort != null) {
serialPort.close();
}
IOUtils.closeQuietly(inputStream);
}

@Override
Expand Down

0 comments on commit 593dbc1

Please sign in to comment.