modified refreshBeacon func's rule