fix bug for not g.user