decentralized and customizable links page on top of atproto ligo.at
atproto link-in-bio python uv
9
fork

Configure Feed

Select the types of activity you want to include in your feed.

allow empty profiles

+6 -4
+1 -1
src/db.py
··· 49 49 global_key = f"{name}_db" 50 50 db: sqlite3.Connection | None = g.get(global_key, None) 51 51 if db is None: 52 - db_path: str = app.config[f"{name.upper()}_DB_URL"] 52 + db_path: str = app.config.get(f"{name.upper()}_DB_URL", f"{name}.db") 53 53 db = sqlite3.connect(db_path, check_same_thread=False) 54 54 setattr(g, global_key, db) 55 55 # return rows as dict-like objects
+5 -3
src/main.py
··· 86 86 load_profile(client, pds, did, reload=reload), 87 87 load_links(client, pds, did, reload=reload), 88 88 ) 89 - if profile is None or link_sections is None: 90 - return render_template("error.html", message="profile not found"), 404 89 + 90 + if profile is None: 91 + profile = {} 92 + if link_sections is None: 93 + link_sections = [] 91 94 92 95 if reload: 93 96 # remove the ?reload parameter ··· 99 102 return render_template( 100 103 "profile.html", 101 104 profile=profile, 102 - links=link_sections[0].links, 103 105 sections=link_sections, 104 106 athref=athref, 105 107 )