@@ -69,7 +69,7 @@ export default async function handler(
6969 console . warn ( 'Unauthorized request attempt' , {
7070 ip : req . headers [ 'x-forwarded-for' ] || req . connection . remoteAddress ,
7171 userAgent : req . headers [ 'user-agent' ] ,
72- authToken : authToken ? 'present' : 'missing' ,
72+ authTokenProvided : ! ! authToken ,
7373 timestamp : new Date ( ) . toISOString ( )
7474 } ) ;
7575 return res . status ( 401 ) . json ( { error : "Unauthorized" } ) ;
@@ -127,7 +127,7 @@ export default async function handler(
127127
128128 for ( const wallet of wallets ) {
129129 try {
130- console . log ( ` Processing wallet: (${ wallet . id } )` ) ;
130+ console . log ( ` Processing wallet: (${ wallet . id . slice ( 0 , 8 ) } ... )` ) ;
131131
132132 // Determine network from signer addresses
133133 let network = 1 ; // Default to mainnet
@@ -158,7 +158,7 @@ export default async function handler(
158158
159159 const mWallet = buildMultisigWallet ( walletData , network ) ;
160160 if ( ! mWallet ) {
161- console . error ( `Failed to build multisig wallet for ${ wallet . id } ` ) ;
161+ console . error ( `Failed to build multisig wallet for ${ wallet . id . slice ( 0 , 8 ) } ... ` ) ;
162162 failedInBatch ++ ;
163163 continue ;
164164 }
@@ -194,7 +194,7 @@ export default async function handler(
194194 paymentUtxos = await blockchainProvider . fetchAddressUTxOs ( paymentAddress ) ;
195195 stakeableUtxos = await blockchainProvider . fetchAddressUTxOs ( stakeableAddress ) ;
196196 } catch ( utxoError ) {
197- console . error ( `Failed to fetch UTxOs for wallet ${ wallet . id } :` , utxoError ) ;
197+ console . error ( `Failed to fetch UTxOs for wallet ${ wallet . id . slice ( 0 , 8 ) } ... :` , utxoError ) ;
198198 // Continue with empty UTxOs
199199 }
200200
@@ -214,9 +214,9 @@ export default async function handler(
214214 try {
215215 const fallbackProvider = getProvider ( fallbackNetwork ) ;
216216 utxos = await fallbackProvider . fetchAddressUTxOs ( walletAddress ) ;
217- console . log ( `Successfully fetched ${ utxos . length } UTxOs for wallet ${ wallet . id } on fallback network ${ fallbackNetwork } ` ) ;
217+ console . log ( `Successfully fetched ${ utxos . length } UTxOs for wallet ${ wallet . id . slice ( 0 , 8 ) } ... on fallback network ${ fallbackNetwork } ` ) ;
218218 } catch ( fallbackError ) {
219- console . error ( `Failed to fetch UTxOs for wallet ${ wallet . id } on fallback network ${ fallbackNetwork } :` , fallbackError ) ;
219+ console . error ( `Failed to fetch UTxOs for wallet ${ wallet . id . slice ( 0 , 8 ) } ... on fallback network ${ fallbackNetwork } :` , fallbackError ) ;
220220 // Continue with empty UTxOs - this wallet will show 0 balance
221221 }
222222 }
@@ -244,7 +244,7 @@ export default async function handler(
244244 console . log ( ` ✅ Balance: ${ roundedAdaBalance } ADA` ) ;
245245
246246 } catch ( error ) {
247- console . error ( `Error processing wallet ${ wallet . id } :` , error ) ;
247+ console . error ( `Error processing wallet ${ wallet . id . slice ( 0 , 8 ) } ... :` , error ) ;
248248 failedInBatch ++ ;
249249 }
250250 }
@@ -268,7 +268,7 @@ export default async function handler(
268268 } ) ;
269269 return 1 ;
270270 } catch ( error ) {
271- console . error ( 'Failed to store snapshot for wallet %s:' , walletBalance . walletId , error ) ;
271+ console . error ( 'Failed to store snapshot for wallet %s:' , walletBalance . walletId . slice ( 0 , 8 ) + '...' , error ) ;
272272 return 0 ;
273273 }
274274 } ) ;
0 commit comments