Simplify doc-analysis upload hooks (always fire-and-forget)
All checks were successful
Build and Push Docker Image / build (push) Successful in 8m18s
All checks were successful
Build and Push Docker Image / build (push) Successful in 8m18s
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -422,11 +422,9 @@ export const applicantRouter = router({
|
||||
}
|
||||
|
||||
// Auto-analyze document (fire-and-forget, delayed for presigned upload)
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed, isAutoAnalysisEnabled }) =>
|
||||
isAutoAnalysisEnabled().then((enabled) => {
|
||||
if (enabled) analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
})
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed }) =>
|
||||
analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
).catch(() => {})
|
||||
|
||||
return file
|
||||
|
||||
@@ -207,11 +207,9 @@ export const fileRouter = router({
|
||||
})
|
||||
|
||||
// Auto-analyze document (fire-and-forget, delayed for presigned upload)
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed, isAutoAnalysisEnabled }) =>
|
||||
isAutoAnalysisEnabled().then((enabled) => {
|
||||
if (enabled) analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
})
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed }) =>
|
||||
analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
).catch(() => {})
|
||||
|
||||
return {
|
||||
@@ -1210,11 +1208,9 @@ export const fileRouter = router({
|
||||
})
|
||||
|
||||
// Auto-analyze document (fire-and-forget, delayed for presigned upload)
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed, isAutoAnalysisEnabled }) =>
|
||||
isAutoAnalysisEnabled().then((enabled) => {
|
||||
if (enabled) analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
})
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed }) =>
|
||||
analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
).catch(() => {})
|
||||
|
||||
return { uploadUrl, file }
|
||||
@@ -1527,11 +1523,9 @@ export const fileRouter = router({
|
||||
)
|
||||
|
||||
// Auto-analyze document (fire-and-forget, delayed for presigned upload)
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed, isAutoAnalysisEnabled }) =>
|
||||
isAutoAnalysisEnabled().then((enabled) => {
|
||||
if (enabled) analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
})
|
||||
import('../services/document-analyzer').then(({ analyzeFileDelayed }) =>
|
||||
analyzeFileDelayed(file.id).catch((err) =>
|
||||
console.warn('[DocAnalyzer] Post-upload analysis failed:', err))
|
||||
).catch(() => {})
|
||||
|
||||
return { uploadUrl, file }
|
||||
|
||||
Reference in New Issue
Block a user