Skip to content

Commit

Permalink
Merge pull request #82 from leo42/BugFixing
Browse files Browse the repository at this point in the history
Bug fixing
  • Loading branch information
leo42 authored Feb 14, 2024
2 parents f7befec + eda4b9e commit 890e94e
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Fe/src/components/Multisig/MultisigContainer.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ state= {
dAppConnector: null,
}

componentDidUpdate(prevProps) {
componentDidUpdate(prevProps) {

if (this.props.settings !== prevProps.settings) {
this.newSettings(this.props.root.state.settings)
this.newSettings(this.props.settings)

}
}
Expand Down
2 changes: 1 addition & 1 deletion Fe/src/components/SettingsModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ function SettingsModal(props) {
<span>Metadata Provider</span>
<select onChange={(event) => setMetadataProvider(event.target.value)} value={metadataProvider} defaultValue={metadataProvider}>
<option value="None">None</option>
<option value="Koios">Koios</option>
{/* <option value="Koios">Koios</option> */}
<option value="Maestro">Maestro</option>
{ provider && <option value="Blockfrost">Blockfrost</option> }
</select>
Expand Down
2 changes: 1 addition & 1 deletion Fe/src/components/WalletCreateTx.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ class WalletCreateTx extends React.Component {
</div>
))}
</div>
<TokenDropdownMenu ballances={this.props.wallet.getBalanceFull(this.state.sendFrom)} f={ (tokenId) => this.addToken(tokenId,index )} index={index+this.state.sendFrom}></TokenDropdownMenu>
{ Object.values(this.props.wallet.getBalanceFull(this.state.sendFrom)).length > 1 && <TokenDropdownMenu ballances={this.props.wallet.getBalanceFull(this.state.sendFrom)} f={ (tokenId) => this.addToken(tokenId,index )} index={index+this.state.sendFrom}></TokenDropdownMenu>}
{ this.props.root.state.settings.sendAll ? <label> Send all: <input type="checkbox" checked={this.state.sendAll === index ? true : false } onChange={()=> this.handleSendAlltoggle(index)}></input> </label> : ""}
</div>
))
Expand Down
5 changes: 5 additions & 0 deletions Fe/src/helpers/Messaging.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,12 @@ class Messaging {
async connect() {

// this.port = chrome.runtime.connect("jfjmokidpopgdhcilhkoanmjcimijgng"); // Selfbuild ID
try{
this.port = chrome.runtime.connect("mdnadibcilebgfdkadlhegdpgpglljmn"); //playstore ID
}catch(e){
console.log(e)
return
}
this.port.onMessage.addListener( async (message) => {
if(message.action){
let response
Expand Down
3 changes: 1 addition & 2 deletions Fe/src/helpers/newLucid.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,13 @@ async function getNewLucidInstance(settings){
async function changeProvider(lucid, settings){
return new Promise(async (resolve, reject) => {
const provider = getProvider(settings);
lucid.switchProvider(provider);
await lucid.switchProvider(provider);
resolve(lucid);
});

}

function getProvider(settings){
console.log(settings)
switch(settings.provider){
case "Blockfrost":
return new Blockfrost(settings.api.url, settings.api.projectId);
Expand Down
1 change: 0 additions & 1 deletion Fe/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ class App extends React.Component {
return
}
const settings = {...this.state.settings, ...newSettings}
localStorage.setItem("settings", JSON.stringify(newSettings))

this.setState({settings})
}
Expand Down

0 comments on commit 890e94e

Please sign in to comment.