Browse Source

fixed swapi url

unknown 3 năm trước cách đây
mục cha
commit
d4331332cf
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      javascript/hw.js

+ 1 - 1
javascript/hw.js

@@ -409,7 +409,7 @@ const cachedFetchStarWars = async () => {
 	const lc = await localStorage.getItem('data');
 	const lc = await localStorage.getItem('data');
 	if (lc) return JSON.parse(lc);
 	if (lc) return JSON.parse(lc);
 
 
-	const data = await fetch('https://swapi.dev/api/people/1/')
+	const data = await fetch('https://swapi.py4e.com/api/people/1/')
 		.then((res) => res.json())
 		.then((res) => res.json())
 		.then((data) => {
 		.then((data) => {
 			const newData = {};
 			const newData = {};