Skip to content

Commit

Permalink
Temporary changes for staff release
Browse files Browse the repository at this point in the history
1. `expo-media-library`: don't include videos
2. `mediaConfig`: don't treat animated GIFs as videos
3. Enable `processedMessageStore` invariants for `release` build
4. Enable `processedThreadStore` invariants for `release` build
  • Loading branch information
atulsmadhugiri committed Nov 8, 2021
1 parent 0c1c0d4 commit 71a0034
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/media/file-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const mediaConfig: { [mime: string]: MediaConfig } = Object.freeze({
serverTranscodesImage: true,
},
'image/gif': {
mediaType: 'photo_or_video',
mediaType: 'photo',
extension: 'gif',
serverCanHandle: true,
serverTranscodesImage: true,
Expand Down
3 changes: 1 addition & 2 deletions lib/reducers/message-reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,9 @@ import {
processUpdatesActionType,
} from '../types/update-types';
import { setNewSessionActionType } from '../utils/action-utils';
import { isDev } from '../utils/dev-utils';
import { assertObjectsAreEqual } from '../utils/objects';

const PROCESSED_MSG_STORE_INVARIANTS_DISABLED = !isDev;
const PROCESSED_MSG_STORE_INVARIANTS_DISABLED = false;
const _mapValuesWithKeys = _mapValues.convert({ cap: false });

// Input must already be ordered!
Expand Down
3 changes: 1 addition & 2 deletions lib/reducers/thread-reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,10 @@ import {
import { actionLogger } from '../utils/action-logger';
import { setNewSessionActionType } from '../utils/action-utils';
import { getConfig } from '../utils/config';
import { isDev } from '../utils/dev-utils';
import { assertObjectsAreEqual } from '../utils/objects';
import { sanitizeActionSecrets } from '../utils/sanitization';

const PROCESSED_THREAD_STORE_INVARIANTS_DISABLED = !isDev;
const PROCESSED_THREAD_STORE_INVARIANTS_DISABLED = false;

function reduceThreadUpdates(
threadInfos: { +[id: string]: RawThreadInfo },
Expand Down
2 changes: 1 addition & 1 deletion native/media/media-gallery-keyboard.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ class MediaGalleryKeyboard extends React.PureComponent<Props, State> {
} = await MediaLibrary.getAssetsAsync({
first: 20,
after,
mediaType: [MediaLibrary.MediaType.photo, MediaLibrary.MediaType.video],
mediaType: [MediaLibrary.MediaType.photo],
sortBy: [MediaLibrary.SortBy.modificationTime],
});

Expand Down

0 comments on commit 71a0034

Please sign in to comment.