Fix wrong time calculation for rmedge