Skip to content

Commit

Permalink
unwind debug commented out logic
Browse files Browse the repository at this point in the history
  • Loading branch information
kadamidev committed Oct 23, 2024
1 parent 586873f commit dd761ad
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions desci-server/src/controllers/admin/debug.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,12 @@ const debugMigration = async (uuid?: string, stream?: DebugStreamResponse) => {
const legacyHistory = await _getIndexedResearchObjects([uuid]);
const legacyHistoryPresent = !!legacyHistory?.researchObjects?.length;

// if (!legacyHistoryPresent || !stream.present)
// return { legacyHistory: legacyHistoryPresent, streamHistory: stream.present };
if (!legacyHistoryPresent || !stream.present)
return { legacyHistory: legacyHistoryPresent, streamHistory: stream.present };

const streamController =
stream.present && 'state' in stream.raw ? stream.raw.state.metadata.controllers[0].split(':').pop() : undefined;
const legacyOwner = legacyHistory.researchObjects[0]?.owner;
const legacyOwner = legacyHistory.researchObjects[0].owner;

// Stream Controller === Legacy Contract RO Owner Check
const ownerMatches = streamController?.toLowerCase() === legacyOwner?.toLowerCase();
Expand Down

0 comments on commit dd761ad

Please sign in to comment.