diff --git a/docs/changelog/6.x.x.txt b/docs/changelog/6.x.x.txt index c972b513d..dc1cb8576 100644 --- a/docs/changelog/6.x.x.txt +++ b/docs/changelog/6.x.x.txt @@ -1,6 +1,8 @@ 6.8.1 - Upgraded TinyMCE to 2.0.1, which allows the rich editor to work with Firefox 1.5. + - Now that we're requiring Perl 5.8, don't need to do the hackery for WS + Client to work any longer. 6.8.0 - Switched Date::Manip to DateTime for better performance and more diff --git a/docs/gotcha.txt b/docs/gotcha.txt index 433320dcb..39562e9bb 100644 --- a/docs/gotcha.txt +++ b/docs/gotcha.txt @@ -7,6 +7,12 @@ upgrading from one version to the next, or even between multiple versions. Be sure to heed the warnings contained herein as they will save you many hours of grief. +6.8.0 +-------------------------------------------------------------------- + * Before upgrading you must install the following new Perl modules: + Data::Structure::Util + + 6.8.0 -------------------------------------------------------------------- * Before upgrading you must install the following new Perl modules: @@ -78,6 +84,8 @@ save you many hours of grief. which will increase performance, and add to our functionality for the future. + * WebGUI now requires Perl 5.8 to operate. + * The Macro API has been changed. If you have any third-party macros installed make sure to update them prior to upgrading. See docs/migration.txt for details. diff --git a/lib/WebGUI/Asset/Wobject/WSClient.pm b/lib/WebGUI/Asset/Wobject/WSClient.pm index 644c2ee18..5ba42d2ec 100644 --- a/lib/WebGUI/Asset/Wobject/WSClient.pm +++ b/lib/WebGUI/Asset/Wobject/WSClient.pm @@ -1,6 +1,7 @@ package WebGUI::Asset::Wobject::WSClient; use strict; +use Data::Structure::Util; use Data::Dumper; use Digest::MD5; use SOAP::Lite; @@ -15,30 +16,6 @@ use WebGUI::Privilege; use WebGUI::Session; use WebGUI::Asset::Wobject; -my ($hasUnblessAcme, $hasUnblessData, $hasUtf8, $utf8FieldType); - -# we really would like to be able to unbless references and strip utf8 data, -# but that requires non-standard and possibly difficult to install modules -BEGIN { - - # check for Data::Structure::Util, which requires perl 5.8.0 :-P - eval { require Data::Structure::Util; }; - if ($@) { - - $utf8FieldType = 'hidden'; - - # try Acme::Damn as partial fallback - eval { require Acme::Damn; }; - $hasUnblessAcme = 1 if !$@; - - } else { - - $utf8FieldType = 'yesNo'; - $hasUnblessData = 1; - $hasUtf8 = 1 if $] >= 5.008; - } -} - our @ISA = qw(WebGUI::Asset::Wobject); @@ -113,7 +90,7 @@ my $httpHeaderFieldType; defaultValue => $session{'config'}{'soapuri'} }, decodeUtf8 => { - fieldType => $utf8FieldType, + fieldType => "yesNo", defaultValue => 0, }, httpHeader => { @@ -214,20 +191,12 @@ sub getEditForm { -hoverHelp => WebGUI::International::get('9 description', "Asset_WSClient"), -value => $self->get('debugMode'), ); - if ($utf8FieldType eq 'yesNo') { $tabform->getTab("properties")->yesNo ( -name => 'decodeUtf8', -label => WebGUI::International::get(15, "Asset_WSClient"), -hoverHelp => WebGUI::International::get('15 description', "Asset_WSClient"), -value => $self->get('decodeUtf8'), ); - } else { - $tabform->getTab("properties")->hidden ( - -name => 'decodeUtf8', - -label => WebGUI::International::get(15, "Asset_WSClient"), - -value => $self->get('decodeUtf8'), - ); - } my $cacheopts = { 0 => WebGUI::International::get(29, "Asset_WSClient"), 1 => WebGUI::International::get(19, "Asset_WSClient"), @@ -403,13 +372,8 @@ sub view { } elsif (ref $return eq 'HASH') { @result = $return; - # blessed object, to be stripped with Acme::Damn - } elsif ($hasUnblessAcme && ref $return) { - WebGUI::ErrorHandler::warn("Acme::Damn::unbless($return)"); - @result = Acme::Damn::unbless($return); - # blessed object, to be stripped with Data::Structure::Util - } elsif ($hasUnblessData && ref $return) { + } elsif ( ref $return) { WebGUI::ErrorHandler::warn("Data::Structure::Util::unbless($return)"); @result = Data::Structure::Util::unbless($return); @@ -442,7 +406,7 @@ sub view { # Do we need to decode utf8 data? Will only decode if modules were # loaded and the wobject requests it - if ($self->{'decodeUtf8'} && $hasUtf8) { + if ($self->{'decodeUtf8'}) { if (Data::Structure::Util::has_utf8(\@result)) { @result = @{Data::Structure::Util::utf8_off(\@result)}; } diff --git a/sbin/testEnvironment.pl b/sbin/testEnvironment.pl index a046df0b9..82eec9e73 100644 --- a/sbin/testEnvironment.pl +++ b/sbin/testEnvironment.pl @@ -77,6 +77,7 @@ checkModule("Finance::Quote",1.08); #checkModule("POE",0.3202); #checkModule("POE::Component::IKC::Server",0.18); #checkModule("POE::Component::JobQueue",0.5402); +checkModule("Data::Structure::Util",0.11); checkModule("Apache2::Request",2.06); ###################################