Make Text::Aspell optional. This is mostly to unblock development on HEAD

for those of us who can't get Text::Aspell to work, with no UI components
added to show that the spell checker is disabled.
This commit is contained in:
Drake 2006-10-20 20:56:13 +00:00
parent 37aad09679
commit d5be2abcf3
4 changed files with 6 additions and 3 deletions

View file

@ -1,5 +1,6 @@
7.2.0
- Added server side spellchecker (Martin Kamerbeek / Procolix)
- change: made Text::Aspell optional, nullifying spellchecker if not present
7.1.2
- Fixed a bug that caused workflows to fail if collaboration systems and

View file

@ -19,7 +19,7 @@ use WebGUI::Asset;
use WebGUI::Form;
use WebGUI::Utility;
use WebGUI::International;
use Text::Aspell;
eval 'use Text::Aspell'; # Optional
our @ISA = qw(WebGUI::Asset);

View file

@ -12,7 +12,8 @@ package WebGUI::Operation::SpellCheck;
use strict;
use Encode;
use Text::Aspell;
# Optional, but if unavailable, spell checking will have no effect.
eval 'use Text::Aspell';
use WebGUI::Utility;
=head1 NAME
@ -40,6 +41,7 @@ An instanciated session object.
sub _getSpeller {
my ($baseDir, $userDir, $homeDir);
my $session = shift;
return undef unless Text::Aspell->can('new');
my $speller = Text::Aspell->new;
# Get language

View file

@ -92,7 +92,7 @@ checkModule("URI::Escape","3.28");
checkModule("POSIX");
checkModule("List::Util");
checkModule("Color::Calc");
checkModule("Text::Aspell");
checkModule("Text::Aspell",0.01,2);
###################################
# Checking WebGUI