Change a couple of f-strings to format

This commit is contained in:
PCoder 2019-09-13 19:26:56 +05:30
parent 984005977d
commit 5215ff1edf

View file

@ -12,7 +12,7 @@ def product():
@product.command("list")
def list():
r = requests.get(f"{config('UCLOUD_PAY_SERVER')}/product/list")
r = requests.get("{}/product/list".format(config('UCLOUD_PAY_SERVER')))
print(load_dump_pretty(r.content))
@ -44,5 +44,6 @@ def add(name, realm, seed, product_name, product_description, product_type,
"product_recurring_duration": product_recurring_duration,
"product_recurring_duration_units": product_recurring_duration_units
}
r = requests.post(f"{config('UCLOUD_API_SERVER')}/product/add", json=data)
r = requests.post("{}/product/add".format(config('UCLOUD_API_SERVER')),
json=data)
print(load_dump_pretty(r.content))