Skip to content

Commit

Permalink
Modify warning message (facebook#28514)
Browse files Browse the repository at this point in the history
Summary:
Modify deprecation warning message for `AccessibilityInfo.fetch`

- https://reactnative.dev/docs/accessibilityinfo#isscreenreaderenabled
- facebook@523ab83

## Changelog

[Internal] [Changed] - Modify deprecation warning message for `AccessibilityInfo.fetch`
Pull Request resolved: facebook#28514

Test Plan: Try using `AccessibilityInfo.fetch` and check log

Reviewed By: cpojer

Differential Revision: D20850223

Pulled By: TheSavior

fbshipit-source-id: e21bb20b7a02d9f2ed6e27e2bfecbac0aebf9e09
  • Loading branch information
jiggag authored and facebook-github-bot committed Apr 4, 2020
1 parent e2c417f commit caa7829
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ const AccessibilityInfo = {
*/
get fetch(): () => Promise<boolean> {
console.warn(
'AccessibilityInfo.fetch is deprecated, call Accessibility.isScreenReaderEnabled instead',
'AccessibilityInfo.fetch is deprecated, call AccessibilityInfo.isScreenReaderEnabled instead',
);
return this.isScreenReaderEnabled;
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ const AccessibilityInfo = {
*/
get fetch(): $FlowFixMe {
console.warn(
'AccessibilityInfo.fetch is deprecated, call Accessibility.isScreenReaderEnabled instead',
'AccessibilityInfo.fetch is deprecated, call AccessibilityInfo.isScreenReaderEnabled instead',
);
return this.isScreenReaderEnabled;
},
Expand Down

0 comments on commit caa7829

Please sign in to comment.