Skip to content

Commit

Permalink
Update App.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan6sha committed Sep 8, 2023
1 parent 1fa6394 commit 7ab62a2
Showing 1 changed file with 16 additions and 17 deletions.
33 changes: 16 additions & 17 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const App = () => {
var RNFS = require('react-native-fs');
const readFile = () => {
RNFS.readDir(RNFS.DocumentDirectoryPath)
.then((result: { path: any; }[]) => {
.then((result: { path: any }[]) => {
console.log('GOT RESULT', result);
return Promise.all([RNFS.stat(result[0].path), result[0].path]);
})
Expand All @@ -34,7 +34,7 @@ const App = () => {
.then((contents: any) => {
console.log(contents);
})
.catch((err: { message: any; code: any; }) => {
.catch((err: { message: any; code: any }) => {
console.log(err.message, err.code);
});
};
Expand Down Expand Up @@ -109,13 +109,13 @@ const App = () => {
try {
await fula.shutdown();
let clientinit = await fula.newClient(
privateKey.toString()
, ''
, bloxAddr
, bloxAddr? '' : 'noop'
, true
,true
, true
privateKey.toString(),
'',
bloxAddr,
bloxAddr ? '' : 'noop',
true,
true,
true
);
if (clientinit) {
console.log('newClient complete');
Expand Down Expand Up @@ -164,15 +164,14 @@ const App = () => {
/>
<Button
//12D3KooWMMt4C3FKui14ai4r1VWwznRw6DoP5DcgTfzx2D5VZoWx
title={
inprogress
? 'Putting & Getting...'
: 'set auth'
}
title={inprogress ? 'Putting & Getting...' : 'set auth'}
onPress={async () => {
try {
fula
.setAuth('12D3KooWMMt4C3FKui14ai4r1VWwznRw6DoP5DcgTfzx2D5VZoWx', true)
.setAuth(
'12D3KooWMMt4C3FKui14ai4r1VWwznRw6DoP5DcgTfzx2D5VZoWx',
true
)
.then((res: any) => {
console.log('tested');
console.log(res);
Expand Down Expand Up @@ -271,7 +270,7 @@ const App = () => {
});
});
})
.catch((err: { message: any; }) => {
.catch((err: { message: any }) => {
console.log(err.message);
});
} else {
Expand Down Expand Up @@ -344,7 +343,7 @@ const App = () => {
});
});
})
.catch((err: { message: any; }) => {
.catch((err: { message: any }) => {
console.log(err.message);
});
} else {
Expand Down

0 comments on commit 7ab62a2

Please sign in to comment.