handle lastSample in TSRP properly