fixes news?

This commit is contained in:
BalazsManus 2025-02-14 14:13:56 +01:00
parent 1b6992132e
commit df63c258b3
3 changed files with 3 additions and 3 deletions

2
.gitmodules vendored
View File

@ -1,3 +1,3 @@
[submodule "naplo-plus"] [submodule "naplo-plus"]
path = refilc_plus path = refilc_plus
url = git@github.com:refilc/naplo-plus.git url = https://git.qwit.cloud/refilc/student-plus.git

1
.idea/misc.xml generated
View File

@ -1,4 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Android API 33, extension level 3 Platform" project-jdk-type="Android SDK" /> <component name="ProjectRootManager" version="2" project-jdk-name="Android API 33, extension level 3 Platform" project-jdk-type="Android SDK" />
</project> </project>

View File

@ -127,7 +127,8 @@ class FilcAPI {
http.Response res = await http.get(Uri.parse(news)); http.Response res = await http.get(Uri.parse(news));
if (res.statusCode == 200) { if (res.statusCode == 200) {
return (jsonDecode(res.body) as List) String utf8Body = utf9.decode(res.bodyBytes);
return (jsonDecode(utf8Body) as List)
.cast<Map>() .cast<Map>()
.map((e) => News.fromJson(e)) .map((e) => News.fromJson(e))
.toList(); .toList();