-
Notifications
You must be signed in to change notification settings - Fork 122
Fix offline file loading logic #2960
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix offline file loading logic #2960
Conversation
refs: MBL-17935 affects: Student release note: Fixed downloaded files not being available in offline mode. test plan: - Have a course with a course file added to modules. - Sync the course with files for offline mode. - Go offline. - Enter the course's Files menu. - Check if the downloaded file displays in the file viewer. - Go to Modules, test if the linked file in the module item it will display in offline mode. - Smoke test if files are working in online mode.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One edge case, may or may not need a fix:
- In current app version (before this PR) I've synced offline content (used account in ticket)
- Went offline
- Checked that files do not load (as ticket describes), also entered the page with the embedded images
- Embedded images were visible
- Installed PR build + went offline again
- Entered the page with the embedded images
- The embedded images were not displaying (but the links work), even though the images are viewable in modules or module-files tab.
After I synced again, this issue was gone, embedded images were visible.
All else worked as described with or without resyncing.
Core/Core/Files/View/FileDetails/FileDetailsViewController.swift
Outdated
Show resolved
Hide resolved
Core/Core/Files/View/FileDetails/FileDetailsViewController.swift
Outdated
Show resolved
Hide resolved
Co-authored-by: Richárd Harangozó <[email protected]>
Co-authored-by: Richárd Harangozó <[email protected]>
I experienced the exact same behavior. I think it's not related to this PR since offline RCE content rendering happens outside of this file that I modified. I'll take a deeper look on this and create a separate ticket if necessary. |
Thanks! In that case QA + 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
QA +1
What happened?
It seems that at some point during the offline file support delivery we broke the support for offline files when they are opened via a course's Files or Modules menu. The logic to load such offline files was non-existing so I implemented it.
refs: MBL-17935
affects: Student
release note: Fixed downloaded files not being available in offline mode.
test plan:
Checklist