Null check on response write