Skip to content

Commit

Permalink
Added 'content' to allowed uri types
Browse files Browse the repository at this point in the history
  • Loading branch information
Max Rondon committed Sep 20, 2018
1 parent 9789f2e commit 3666064
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ class PdfReader extends Component<Props, State> {
this.setState({ ios, android })

let data = undefined
if(source.uri && source.uri.startsWith('http') || source.uri && source.uri.startsWith('file')) {
if(source.uri && (source.uri.startsWith('http') || source.uri.startsWith('file') || source.uri.startsWith('content'))) {
data = await fetchPdfAsync(source.uri)
} else if (source.base64 && source.base64.startsWith('data')) {
data = source.base64
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rn-pdf-reader-js",
"version": "0.1.7",
"version": "0.1.8",
"description": "PDF reader for Expo",
"main": "index.js",
"author": "Xavier Carpentier <xcapetir@gmail.com> (https://xaviercarpentier.com/)",
Expand Down

0 comments on commit 3666064

Please sign in to comment.