fixed a bug where tableGateway was null