Skip to content

Commit

Permalink
Fix filter handling (fix traccar#3958)
Browse files Browse the repository at this point in the history
  • Loading branch information
tananaev committed Jul 1, 2018
1 parent e849d3a commit b2a9557
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/org/traccar/BaseDataHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ public abstract class BaseDataHandler extends ChannelInboundHandlerAdapter {
@Override
public void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception {
if (msg instanceof Position) {
ctx.fireChannelRead(handlePosition((Position) msg));
Position position = handlePosition((Position) msg);
if (position != null) {
ctx.fireChannelRead(position);
}
} else {
super.channelRead(ctx, msg);
}
Expand Down

0 comments on commit b2a9557

Please sign in to comment.