transition app/twit to serve /home instead of /user

This commit is contained in:
Anton Dyudin 2016-03-22 11:49:04 -07:00
parent 8c657b163c
commit 1ced5c9c47
2 changed files with 13 additions and 13 deletions

View File

@ -8,8 +8,8 @@
::
|%
++ twit-path :: valid peer path
$% :: {$home $~} :: home timeline
{$user p/@t $~} :: user's tweets
$% {$home $~} :: home timeline
:: {$user p/@t $~} :: user's tweets
{$post p/@taxuv $~} :: status of status
==
::
@ -133,7 +133,7 @@
:_ +>.$
=+ pax=/[who.rep]/status/(rsh 3 2 (scot %ui id.rep))
:- (show-url [& ~ &+/com/twitter] `pax ~)
=+ mof=~[[%twit-post rep] [%quit ~]]
=+ mof=~[[%diff %twit-post rep] [%quit ~]]
(weld (spam post+wir mof) (spam scry+x+post+wir mof))
::
++ sigh-twit-feed :: feed data
@ -235,7 +235,7 @@
[%none ~]
[%full twit-post+p.u.sta]
::
$user ::?($user $home)
$home ::?($user $home)
[%part twit-feed+(flop (~(get ja fed) pax))]
==
::
@ -243,15 +243,15 @@
|= pax/twit-path ^- (unit api-call)
?- -.pax
$post ~ :: future/unacked
$user
=+ ole=(~(get ja fed) pax)
=+ opt=?~(ole ~ ['since_id' (tid:print id.i.ole)]~)
`[%twit-feed twit-req+[stat-user+[(to-sd p.pax)]~ opt]]
::
:: $home
:: $user
:: =+ ole=(~(get ja fed) pax)
:: =+ opt=?~(ole ~ ['since_id' (tid:print id.i.ole)]~)
:: `[%twit-feed stat-home+~ opt]
:: `[%twit-feed twit-req+[stat-user+[(to-sd p.pax)]~ opt]]
:: ::
$home
=+ ole=(~(get ja fed) pax)
=+ opt=?~(ole ~ ['since_id' (tid:print id.i.ole)]~)
`[%twit-feed twit-req+[stat-home+~ opt]]
==
::
++ to-sd :: parse user name/numb

View File

@ -58,7 +58,7 @@
$get [url med *math ~]
$post
=+ hed=(my content-type+['application/x-www-form-urlencoded']~ ~)
[url(r ~) med hed (some (tact +:(tail:earn r.url)))]
[url(r ~) med hed ?~(r.url ~ (some (tact +:(tail:earn r.url))))]
==
::
++ find-req
@ -123,7 +123,7 @@
=+ args:reqs
|%
++ apex
|= {a/endpoint b/quay}
|= {a/endpoint b/quay} ^- hiss
=+ [med pax]=(find-req -.a)
(valve med (cowl pax +.a b))
::