fixed bug of offline