From 7b7fbceedc75296c20dbec032d07f45bebad15ac Mon Sep 17 00:00:00 2001 From: ruidajo Date: Thu, 18 May 2023 11:29:19 -0500 Subject: [PATCH] Modifying nitter provider and improving created format parse for user. --- .../NitterUser.class/class/nitterProvider.st | 2 +- .../NitterUser.class/instance/createdAt.st | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Socialmetrica.package/NitterUser.class/class/nitterProvider.st b/Socialmetrica.package/NitterUser.class/class/nitterProvider.st index 5f2d347..e215d39 100644 --- a/Socialmetrica.package/NitterUser.class/class/nitterProvider.st +++ b/Socialmetrica.package/NitterUser.class/class/nitterProvider.st @@ -3,4 +3,4 @@ nitterProvider "For a full list of Nitter providers, see: https://github.com/zedeus/nitter/wiki/Instances" - ^ 'https://nitter.ca/' \ No newline at end of file + ^ 'https://nitter.net/' \ No newline at end of file diff --git a/Socialmetrica.package/NitterUser.class/instance/createdAt.st b/Socialmetrica.package/NitterUser.class/instance/createdAt.st index ab72b75..745e915 100644 --- a/Socialmetrica.package/NitterUser.class/instance/createdAt.st +++ b/Socialmetrica.package/NitterUser.class/instance/createdAt.st @@ -2,9 +2,9 @@ accessing createdAt ^ createdAt ifNil: [| joinDateString | joinDateString := ((self documentTree xpath: '//div[@class="profile-joindate"]/span/@title') stringValue). - joinDateString := joinDateString copyReplaceAll: '3 May' with: '03 May'. + "joinDateString := joinDateString copyReplaceAll: '3 May' with: '03 May'. joinDateString := joinDateString copyReplaceAll: '5 May' with: '05 May'. joinDateString := joinDateString copyReplaceAll: '2 Feb' with: '02 Feb'. - joinDateString := joinDateString copyReplaceAll: '6 Mar' with: '06 Mar'. - createdAt := (ZTimestampFormat fromString:'4:05 PM - 03 Feb 2001') parse: joinDateString. + joinDateString := joinDateString copyReplaceAll: '6 Mar' with: '06 Mar'." + createdAt := (ZTimestampFormat fromString:'4:05 PM - 3 Feb 2001') parse: joinDateString. ] \ No newline at end of file