private bool GetNextRow()

in src/SqlAsyncEnumerable.cs [102:122]


            private bool GetNextRow()
            {
                // check connection state before trying to access the reader
                // if DisposeAsync has already closed it due to the issue described here https://github.com/Azure/azure-functions-sql-extension/issues/350
                if (this._connection.State != System.Data.ConnectionState.Closed)
                {
                    if (this._reader == null)
                    {
                        using (SqlCommand command = SqlBindingUtilities.BuildCommand(this._attribute, this._connection))
                        {
                            this._reader = command.ExecuteReader();
                        }
                    }
                    if (this._reader.Read())
                    {
                        this.Current = Utils.JsonDeserializeObject<T>(this.SerializeRow());
                        return true;
                    }
                }
                return false;
            }