objective categorical abstract machine language personal data server
65
fork

Configure Feed

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

Add transition scopes support

futurGH d00ea876 591348a2

+25
+25
pegasus/lib/oauth/scopes.ml
··· 424 424 425 425 let has_transition_chat_bsky scopes = 426 426 List.mem (Static TransitionChatBsky) scopes 427 + 428 + module Transition = struct 429 + let allows_account scopes (opts : account_match) = 430 + if opts.attr = Email && opts.action == Read && has_transition_email scopes 431 + then true 432 + else allows_account scopes opts 433 + 434 + let allows_blob scopes (opts : blob_match) = 435 + if has_transition_generic scopes then true else allows_blob scopes opts 436 + 437 + let allows_repo scopes (opts : repo_match) = 438 + if has_transition_generic scopes then true else allows_repo scopes opts 439 + 440 + let allows_rpc scopes (opts : rpc_match) = 441 + if opts.lxm = "*" && has_transition_generic scopes then true 442 + else if 443 + (not (String.starts_with opts.lxm ~prefix:"chat.bsky.")) 444 + && has_transition_generic scopes 445 + then true 446 + else if 447 + String.starts_with opts.lxm ~prefix:"chat.bsky." 448 + && has_transition_chat_bsky scopes 449 + then true 450 + else allows_rpc scopes opts 451 + end