buffer is nil sometimes, just ignore

apparently the buffer is gone before the operation is finished
sometimes, it seems that the standard practice throughout the codebase
is to just check if the buffer is not nil (evaluates to true).