Skip to content

Commit dff24d3

Browse files
committed
check nil
1 parent cfdaadd commit dff24d3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

table/table.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@ type TransactionSettings struct {
4242
}
4343

4444
func (t *TransactionSettings) Settings() *Ydb_Table.TransactionSettings {
45+
if t == nil {
46+
return nil
47+
}
4548
return &t.settings
4649
}
4750

@@ -161,6 +164,9 @@ type TransactionControl struct {
161164
}
162165

163166
func (t *TransactionControl) Desc() *Ydb_Table.TransactionControl {
167+
if t == nil {
168+
return nil
169+
}
164170
return &t.desc
165171
}
166172

0 commit comments

Comments
 (0)