From 61c22a4f4fbed418213fd450f0a23a1e6addd027 Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 11:44:53 +0200 Subject: [PATCH] Author was removed in Pharo 13: disregard setting the author when using version 13... --- .../WADevelopment.class/class/ensureAuthorInitialsWith..st | 3 ++- .../instance/seasideIsAuthorNameSet.st | 4 +++- .../instance/seasideSetAuthorName..st | 4 +++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st b/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st index 9b0dc1d36..b4ac5843a 100644 --- a/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st +++ b/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st @@ -7,7 +7,8 @@ ensureAuthorInitialsWith: aOneArgumentBlock ifTrue: [ "Special Pharo code path to avoid deprecation" | author | - author := Smalltalk at: #Author. + SystemVersion current major >= 13 ifTrue:[ ^ self. "do nothing because Author does not exist anymore" ]. + author := Smalltalk at: #Author ifAbsent: [ nil ]. author isNil ifTrue: [ ^ self error: 'unsupported Pharo version' ]. author fullNamePerSe isEmptyOrNil diff --git a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st index 25e394870..b305eb31d 100644 --- a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st +++ b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st @@ -1,3 +1,5 @@ *seaside-pharo-welcome seasideIsAuthorNameSet - ^ Author fullNamePerSe isEmptyOrNil not \ No newline at end of file + + SystemVersion current major >= 13 ifTrue:[ ^ true. "Author does not exist anymore" ]. + ^ (Smalltalk at: #Author) fullNamePerSe isEmptyOrNil not \ No newline at end of file diff --git a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st index 5f7a84cad..98a40c20c 100644 --- a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st +++ b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st @@ -1,3 +1,5 @@ *seaside-pharo-welcome seasideSetAuthorName: anAuthorName - Author fullName: anAuthorName \ No newline at end of file + + SystemVersion current major >= 13 ifTrue:[ ^ self error: 'Author does not exist anymore.' ]. + (Smalltalk at: #Author) fullName: anAuthorName \ No newline at end of file