File tree Expand file tree Collapse file tree 2 files changed +1
-5
lines changed
controller/postgrescluster Expand file tree Collapse file tree 2 files changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ func (*Reconciler) generatePostgresHBAs(
5959 result := new (postgres.OrderedHBAs )
6060 result .Append (builtin .Mandatory ... )
6161
62- // Append any rules specified in the the Patroni section.
62+ // Append any rules specified in the Patroni section.
6363 before := result .Length ()
6464 result .AppendUnstructured (patroni .PostgresHBAs (cluster .Spec .Patroni )... )
6565
Original file line number Diff line number Diff line change @@ -160,8 +160,6 @@ type OrderedHBAs struct {
160160
161161// Append renders and adds pg_hba.conf lines to o. Nil pointers are ignored.
162162func (o * OrderedHBAs ) Append (hbas ... * HostBasedAuthentication ) {
163- o .records = slices .Grow (o .records , len (hbas ))
164-
165163 for _ , hba := range hbas {
166164 if hba != nil {
167165 o .records = append (o .records , hba .String ())
@@ -172,8 +170,6 @@ func (o *OrderedHBAs) Append(hbas ...*HostBasedAuthentication) {
172170// AppendUnstructured trims and adds unvalidated pg_hba.conf lines to o.
173171// Empty lines and lines that are entirely control characters are omitted.
174172func (o * OrderedHBAs ) AppendUnstructured (hbas ... string ) {
175- o .records = slices .Grow (o .records , len (hbas ))
176-
177173 for _ , hba := range hbas {
178174 hba = strings .TrimFunc (hba , func (r rune ) bool {
179175 // control characters, space, and backslash
You can’t perform that action at this time.
0 commit comments