Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
MDL-11769:
question name is properly truncated to less than 255 characters tom
stop PostGRES choking.
  • Loading branch information
thepurpleblob committed Oct 15, 2007
1 parent 4213137 commit 0db7823
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion question/format/gift/format.php
Expand Up @@ -220,7 +220,8 @@ function readquestion($lines) {
}

// ensure name is not longer than 250 characters
$question->name = shorten_text( $question->name, 250 );
$question->name = shorten_text( $question->name, 200 );
$question->name = strip_tags(substr( $question->name, 0, 250 ));

// determine QUESTION TYPE
$question->qtype = NULL;
Expand Down

0 comments on commit 0db7823

Please sign in to comment.