changed to public server
This commit is contained in:
+2
-1
@@ -6,7 +6,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
const URL = "http://localhost:3000"
|
// const URL = "http://localhost:3000"
|
||||||
|
const URL = "https://pms-xdib.onrender.com"
|
||||||
|
|
||||||
func showHelp() {
|
func showHelp() {
|
||||||
fmt.Println("wpm - Wyst Package Manager")
|
fmt.Println("wpm - Wyst Package Manager")
|
||||||
|
|||||||
+1
-1
@@ -52,7 +52,7 @@ func sendRequest(method, url string, jsonBody []byte) (Request, error) {
|
|||||||
func getPackage(packageName string) (PackageIndex, error) {
|
func getPackage(packageName string) (PackageIndex, error) {
|
||||||
var pkgidx PackageIndex
|
var pkgidx PackageIndex
|
||||||
jsonBody := []byte(fmt.Sprintf(`{"name": "%s"}`, packageName))
|
jsonBody := []byte(fmt.Sprintf(`{"name": "%s"}`, packageName))
|
||||||
req, err := sendRequest(http.MethodGet, "http://localhost:3000", jsonBody)
|
req, err := sendRequest(http.MethodGet, URL, jsonBody)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Printf("Fetching error: %s\n", err)
|
fmt.Printf("Fetching error: %s\n", err)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user