Added author + pack version (#6)

* Added author + pack version

* Remove unnecessary binary

* Apply suggestions, clean up somewhat

Co-authored-by: comp500 <comp500@users.noreply.github.com>
This commit is contained in:
ThetaDev
2020-11-28 18:10:29 +01:00
committed by GitHub
parent 2ca4ad91f9
commit a87f7b50f0
5 changed files with 90 additions and 62 deletions

View File

@@ -346,3 +346,19 @@ func (u cfUpdater) DoUpdate(mods []*core.Mod, cachedState []interface{}) error {
return nil
}
type cfExportData struct {
ProjectID int `mapstructure:"project-id"`
}
func (e cfExportData) ToMap() (map[string]interface{}, error) {
newMap := make(map[string]interface{})
err := mapstructure.Decode(e, &newMap)
return newMap, err
}
func parseExportData(from map[string]interface{}) (cfExportData, error) {
var exportData cfExportData
err := mapstructure.Decode(from, &exportData)
return exportData, err
}