Tweet ODBM preliminar model working. TwitterUser storage needs fixing.

This commit is contained in:
Offray Vladimir Luna Cárdenas 2022-04-06 09:50:50 -05:00
parent 20f12bfcfc
commit 9d3769b21a
4 changed files with 8 additions and 3 deletions

View File

@ -4,6 +4,6 @@ reStoreDefinition
defineAsID: #id;
define: #text as: String;
define: #created as: String;
define: #user as: TwitterUser;
define: #authorId as: String;
define: #timelines as: (Dictionary of: String -> String);
yourself

View File

@ -0,0 +1,3 @@
accessing
authorId
^ authorId ifNil: [ self user id ]

View File

@ -6,4 +6,5 @@ fromNitterRssItem: xmlItem
userName: author .
created := (xmlItem xpath: 'pubDate') stringValue.
text := (xmlItem xpath: 'description') stringValue.
id := ((xmlItem xpath: 'guid') stringValue splitOn: '/') last copyReplaceAll: '#m' with: ''
id := ((xmlItem xpath: 'guid') stringValue splitOn: '/') last copyReplaceAll: '#m' with: ''.
authorId := self user id.

View File

@ -1,7 +1,8 @@
accessing
reStoreDefinition
^ super reStoreDefinition
define: #id as: String;
defineAsID: #id;
define: #userName as: String;
define: #profileImageUrl as: String;
define: #profileBio as: String;
yourself.