mirror of
https://github.com/overte-org/overte.git
synced 2025-08-07 00:44:38 +02:00
Merge pull request #14120 from zfox23/MS18609_snapShareBugs
Fix MS18609: Various Snapshot sharing bugs
This commit is contained in:
commit
bbccd0ff73
1 changed files with 10 additions and 3 deletions
|
@ -44,7 +44,10 @@ try {
|
||||||
}
|
}
|
||||||
|
|
||||||
function removeFromStoryIDsToMaybeDelete(story_id) {
|
function removeFromStoryIDsToMaybeDelete(story_id) {
|
||||||
storyIDsToMaybeDelete.splice(storyIDsToMaybeDelete.indexOf(story_id), 1);
|
story_id = parseInt(story_id);
|
||||||
|
if (storyIDsToMaybeDelete.indexOf(story_id) > -1) {
|
||||||
|
storyIDsToMaybeDelete.splice(storyIDsToMaybeDelete.indexOf(story_id), 1);
|
||||||
|
}
|
||||||
print('storyIDsToMaybeDelete[] now:', JSON.stringify(storyIDsToMaybeDelete));
|
print('storyIDsToMaybeDelete[] now:', JSON.stringify(storyIDsToMaybeDelete));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -258,6 +261,7 @@ function onMessage(message) {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'removeFromStoryIDsToMaybeDelete':
|
case 'removeFromStoryIDsToMaybeDelete':
|
||||||
|
console.log("Facebook OR Twitter button clicked for story_id " + message.story_id);
|
||||||
removeFromStoryIDsToMaybeDelete(message.story_id);
|
removeFromStoryIDsToMaybeDelete(message.story_id);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -333,11 +337,13 @@ function fillImageDataFromPrevious() {
|
||||||
var previousAnimatedSnapStoryID = Settings.getValue("previousAnimatedSnapStoryID");
|
var previousAnimatedSnapStoryID = Settings.getValue("previousAnimatedSnapStoryID");
|
||||||
var previousAnimatedSnapBlastingDisabled = Settings.getValue("previousAnimatedSnapBlastingDisabled");
|
var previousAnimatedSnapBlastingDisabled = Settings.getValue("previousAnimatedSnapBlastingDisabled");
|
||||||
var previousAnimatedSnapHifiSharingDisabled = Settings.getValue("previousAnimatedSnapHifiSharingDisabled");
|
var previousAnimatedSnapHifiSharingDisabled = Settings.getValue("previousAnimatedSnapHifiSharingDisabled");
|
||||||
|
|
||||||
snapshotOptions = {
|
snapshotOptions = {
|
||||||
containsGif: previousAnimatedSnapPath !== "",
|
containsGif: previousAnimatedSnapPath !== "",
|
||||||
processingGif: false,
|
processingGif: false,
|
||||||
shouldUpload: false,
|
shouldUpload: false,
|
||||||
canBlast: snapshotDomainID === Settings.getValue("previousSnapshotDomainID"),
|
canBlast: snapshotDomainID === Settings.getValue("previousSnapshotDomainID") &&
|
||||||
|
snapshotDomainID === location.domainID,
|
||||||
isLoggedIn: isLoggedIn
|
isLoggedIn: isLoggedIn
|
||||||
};
|
};
|
||||||
imageData = [];
|
imageData = [];
|
||||||
|
@ -369,7 +375,8 @@ function snapshotUploaded(isError, reply) {
|
||||||
isGif = fileExtensionMatches(imageURL, "gif"),
|
isGif = fileExtensionMatches(imageURL, "gif"),
|
||||||
ignoreGifSnapshotData = false,
|
ignoreGifSnapshotData = false,
|
||||||
ignoreStillSnapshotData = false;
|
ignoreStillSnapshotData = false;
|
||||||
storyIDsToMaybeDelete.push(storyID);
|
storyIDsToMaybeDelete.push(parseInt(storyID));
|
||||||
|
print('storyIDsToMaybeDelete[] now:', JSON.stringify(storyIDsToMaybeDelete));
|
||||||
if (isGif) {
|
if (isGif) {
|
||||||
if (mostRecentGifSnapshotFilename !== replyJson.user_story.details.original_image_file_name) {
|
if (mostRecentGifSnapshotFilename !== replyJson.user_story.details.original_image_file_name) {
|
||||||
ignoreGifSnapshotData = true;
|
ignoreGifSnapshotData = true;
|
||||||
|
|
Loading…
Reference in a new issue