fixed stability bugs