Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
carina-akaia committed Sep 9, 2024
1 parent 74e4bc1 commit 6aab899
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
5 changes: 3 additions & 2 deletions src/modules/pot-editor/hooks/forms.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,10 @@ export const usePotEditorForm = ({ schema, ...props }: PotEditorFormArgs) => {
dispatch.potEditor.save(
isNewPot
? (inputs as PotEditorDeploymentInputs)
: (inputs as PotEditorSettings),
: { potId, ...(inputs as PotEditorSettings) },
),
[isNewPot],

[isNewPot, potId],
);

useEffect(() => {
Expand Down
6 changes: 0 additions & 6 deletions src/modules/pot-editor/models/effects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ export const effects = (dispatch: RootDispatcher) => ({
Partial<ByPotId>): Promise<void> => {
const isNewPot = typeof potId !== "string";

console.log(isNewPot);

if (commit_hash === null) {
dispatch.potEditor.deploymentFailure(
new Error(
Expand All @@ -46,8 +44,6 @@ export const effects = (dispatch: RootDispatcher) => ({
});

if (isNewPot) {
console.log(pot_args);

potFactory
.deploy_pot({
pot_args,
Expand All @@ -56,8 +52,6 @@ export const effects = (dispatch: RootDispatcher) => ({
.then(dispatch.potEditor.handleDeploymentSuccess)
.catch(dispatch.potEditor.deploymentFailure);
} else {
console.log(omit(pot_args, ["custom_sybil_checks"]));

pot.admin_dangerously_set_pot_config(potId, {
update_args: omit(pot_args, ["custom_sybil_checks"]),
});
Expand Down

0 comments on commit 6aab899

Please sign in to comment.