Added some pending writes stuff