consterrors=db.prepare("SELECT scope,message,created_at FROM error_events ORDER BY id DESC LIMIT 30").all()asany[];
constaudits=db.prepare("SELECT a.action,a.target_type,a.target_id,a.metadata_json,a.created_at,u.username FROM audit_events a LEFT JOIN users u ON u.id=a.actor_user_id ORDER BY a.id DESC LIMIT 50").all()asany[];
constsources=db.prepare("SELECT s.id,s.name,s.base_url,s.sync_status,s.last_synced_at,s.is_enabled,count(sm.user_id) AS member_count FROM sources s LEFT JOIN source_members sm ON sm.source_id=s.id GROUP BY s.id ORDER BY s.id DESC").all()asany[];
if(session.length<32||session==="development-only-change-me"||session.includes("replace-with"))errors.push("SESSION_SECRET must be a non-default value of at least 32 characters");
if(!/^[0-9a-f]{64}$/i.test(encryption))errors.push("TOKEN_ENCRYPTION_KEY must be 64 hexadecimal characters");
try{if(newURL(publicUrl).protocol!=="https:")thrownewError();}catch{errors.push("NEXT_PUBLIC_APP_URL must be an HTTPS URL in production");}
return{ok: errors.length===0,errors};
}
exportfunctionrequireRuntimeConfig() {conststatus=checkRuntimeConfig();if(!status.ok)thrownewError(`Invalid production configuration: ${status.errors.join("; ")}`);}
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.