some necessay code