webapps.pastebin: Rename

Doug Coleman 2013-03-24 10:04:20 -07:00
parent 8c3e9e495c
commit 5436d09c00
1 changed files with 8 additions and 8 deletions

View File

@ -52,16 +52,16 @@ M: entity feed-entry-date date>> ;
M: entity feed-entry-url entity-url ;
TUPLE: paste < entity annotations ;
TUPLE: paste-state < entity annotations ;
\ paste "PASTES" { } define-persistent
\ paste-state "PASTES" { } define-persistent
: <paste> ( id -- paste )
\ paste new
: <paste-state> ( id -- paste )
\ paste-state new
swap >>id ;
: pastes ( -- pastes )
f <paste> select-tuples
f <paste-state> select-tuples
[ date>> ] sort-with
reverse ;
@ -81,7 +81,7 @@ TUPLE: annotation < entity parent ;
[ f ] dip <annotation> select-tuple ;
: paste ( id -- paste )
[ <paste> select-tuple ]
[ <paste-state> select-tuple ]
[ f <annotation> select-tuples ]
bi >>annotations ;
@ -180,7 +180,7 @@ M: annotation entity-url
] >>validate
[
f <paste>
f <paste-state>
[ deposit-entity-slots ]
[ insert-tuple ]
[ id>> paste-url <redirect> ]
@ -194,7 +194,7 @@ M: annotation entity-url
[
[
"id" value <paste> delete-tuples
"id" value <paste-state> delete-tuples
"id" value f <annotation> delete-tuples
] with-transaction
pastebin-url <redirect>