makeProviderAPI constructs an appapi.ProviderAPI from the persistent CLI state. --store selects the SQLite DB path.
(state *globalState)
| 26 | // makeProviderAPI constructs an appapi.ProviderAPI from the persistent CLI |
| 27 | // state. --store selects the SQLite DB path. |
| 28 | func makeProviderAPI(state *globalState) appapi.ProviderAPI { |
| 29 | api := appapi.ProviderAPI{} |
| 30 | if state != nil && state.storePath != "" { |
| 31 | api.DBPath = state.storePath |
| 32 | } |
| 33 | return api |
| 34 | } |
| 35 | |
| 36 | // errEndpointsHandled is returned by PersistentPreRunE when the --endpoints |
| 37 | // short-circuit ran successfully. App.Run recognises it and exits with code |
no outgoing calls
no test coverage detected