scansessions method implemetned but the bug found