Tried to fix the drain function

It still doesn't work.