Fix typing on generateServiceDetail function
This commit is contained in:
parent
e0a5bd86d7
commit
8e325339bf
@ -21,7 +21,7 @@ func ConvertServiceType(input *upstreamApi.JsonScheduleV1, vstp bool) (*database
|
|||||||
PlanSpeed: parseSpeed(&input.ScheduleSegment.CifSpeed),
|
PlanSpeed: parseSpeed(&input.ScheduleSegment.CifSpeed),
|
||||||
ScheduleStartDate: ParseCifDate(&input.ScheduleStartDate, "start"),
|
ScheduleStartDate: ParseCifDate(&input.ScheduleStartDate, "start"),
|
||||||
ScheduleEndDate: ParseCifDate(&input.ScheduleEndDate, "end"),
|
ScheduleEndDate: ParseCifDate(&input.ScheduleEndDate, "end"),
|
||||||
ServiceDetail: generateServiceDetail(&input.ScheduleSegment.CifTrainClass, &input.ScheduleSegment.SignallingId, &input.ScheduleSegment.CifCateringCode, &input.ScheduleSegment.CifSleepers, &input.ScheduleSegment.CifOperatingCharacteristics, vstp),
|
ServiceDetail: generateServiceDetail(&input.ScheduleSegment.CifTrainClass, &input.ScheduleSegment.SignallingId, &input.ScheduleSegment.CifCateringCode, &input.ScheduleSegment.CifSleepers, vstp),
|
||||||
DaysRun: parseDaysRun(&input.ScheduleDaysRun),
|
DaysRun: parseDaysRun(&input.ScheduleDaysRun),
|
||||||
Stops: parseStops(&input.ScheduleSegment.ScheduleLocation),
|
Stops: parseStops(&input.ScheduleSegment.ScheduleLocation),
|
||||||
}
|
}
|
||||||
@ -85,8 +85,7 @@ func isPublic(input *upstreamApi.CifScheduleLocation) bool {
|
|||||||
// Generates a ServiceDetail struct based on the input
|
// Generates a ServiceDetail struct based on the input
|
||||||
func generateServiceDetail(
|
func generateServiceDetail(
|
||||||
cifTrainClass, signallingId,
|
cifTrainClass, signallingId,
|
||||||
cateringCode, sleepers,
|
cateringCode, sleepers *string,
|
||||||
operatingCharacteristics *string,
|
|
||||||
vstp bool,
|
vstp bool,
|
||||||
) database.ServiceDetail {
|
) database.ServiceDetail {
|
||||||
return database.ServiceDetail{
|
return database.ServiceDetail{
|
||||||
|
Loading…
Reference in New Issue
Block a user