File tree Expand file tree Collapse file tree 1 file changed +10
-7
lines changed
Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -71,17 +71,20 @@ namespace appimage::update {
7171 }
7272
7373 void validateAppImage () {
74- const auto rawUpdateInformationFromAppImage = appImage.readRawUpdateInformation ();
75-
7674 // first check whether there's update information at all
77- if (rawUpdateInformationFromAppImage.empty ()) {
78- std::ostringstream oss;
79- oss << " Could not find update information in the AppImage. "
75+ // note that we skip this check when custom update information is set intentionally
76+ if (this ->rawUpdateInformation .empty ()) {
77+ const auto rawUpdateInformationFromAppImage = appImage.readRawUpdateInformation ();
78+
79+ if (rawUpdateInformationFromAppImage.empty ()) {
80+ std::ostringstream oss;
81+ oss << " Could not find update information in the AppImage. "
8082 << " Please contact the author of the AppImage and ask them to embed update information." ;
81- throw AppImageError (oss.str ());
83+ throw AppImageError (oss.str ());
84+ }
8285 }
8386
84- const auto updateInformationPtr = makeUpdateInformation (rawUpdateInformationFromAppImage );
87+ const auto updateInformationPtr = makeUpdateInformation (rawUpdateInformation );
8588 const auto zsyncUrl = updateInformationPtr->buildUrl (makeIssueStatusMessageCallback ());
8689
8790 // now check whether a ZSync URL could be composed by readAppImage
You can’t perform that action at this time.
0 commit comments