...
 
Commits (3)
import React, { Component } from 'react';
import { Text, TextInput, View, StyleSheet } from 'react-native';
import { Text, TextInput, View, StyleSheet, Platform } from 'react-native';
import { inject, observer } from 'mobx-react/native';
import FaIcon from 'react-native-vector-icons/FontAwesome';
import IonIcon from 'react-native-vector-icons/Ionicons';
......@@ -326,7 +326,7 @@ export default class CapturePosterFlags extends Component {
}
renderNsfw() {
if (GOOGLE_PLAY_STORE) return null;
if (GOOGLE_PLAY_STORE || Platform.OS === 'ios') return null;
return (
<NsfwToggle
containerStyle={styles.cell}
......
import AsyncStorage from '@react-native-community/async-storage';
import { Platform } from "react-native";
class NsfwService {
constructor(target) {
......@@ -13,6 +14,7 @@ class NsfwService {
* @returns {Promise<number[]>}
*/
async get() {
if (Platform.OS === 'ios') return [];
try {
const value = await AsyncStorage.getItem(this._getStorageKey());
return value ? JSON.parse(value) : [];
......
......@@ -9,6 +9,7 @@ import {
LayoutAnimation,
TouchableHighlight,
StyleSheet,
Platform,
} from 'react-native';
import {
......@@ -172,7 +173,7 @@ export default class NewsfeedFilters extends Component {
</View>
</TouchableHighlight>
</View>
{!GOOGLE_PLAY_STORE && <View style={[CS.padding, CS.paddingLeft2x, CS.paddingRight2x]}>
{(!GOOGLE_PLAY_STORE && Platform.OS !== 'ios') && <View style={[CS.padding, CS.paddingLeft2x, CS.paddingRight2x]}>
<NsfwToggle
hideLabel={true}
value={store.nsfw}
......