psi: made TimeLocation struct member vars exported

This commit is contained in:
saxon 2019-01-07 12:05:05 +10:30
parent 7a73f69fe9
commit 239e1dfc93
1 changed files with 6 additions and 6 deletions

View File

@ -42,18 +42,18 @@ const (
)
type TimeLocation struct {
time uint64
location string
Time uint64
Location string
}
var metaData = TimeLocation{}
func SetTimeStamp(t uint64) {
metaData.time = t
metaData.Time = t
}
func SetLocation(g string) {
metaData.location = g
metaData.Location = g
}
var (
@ -186,11 +186,11 @@ func (e *Encoder) writePSI() error {
}
// Update pmt table time and location
err = psi.UpdateTime(pmtTable, metaData.time)
err = psi.UpdateTime(pmtTable, metaData.Time)
if err != nil {
return err
}
err = psi.UpdateLocation(pmtTable, metaData.location)
err = psi.UpdateLocation(pmtTable, metaData.Location)
if err != nil {
return nil
}