Made changes to deleting the container from list of containers in the session

Just searched through the list and did a splice at the location
To match the patterns of the rest of the codebase, the preferred pattern here would be something like

````javascript
tx.commit(function (err) {
  if (err) {
    return callback(err);
  }

  for (... this.containers) {
    ...
````

This is the preferred pattern because it

* explicitly returns early, stopping the execution of the subsequent code if there is an error
* allows you to reduce the indentation of the subsequent code