Project

General

Profile

Actions

Defect #22

closed

New Wiki , cannot create new page.

Added by Jeffrey Jones over 17 years ago. Updated over 17 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Affected version:

Description

Based on SVN trunk.

When I created a new Wiki and tried to access the new wiki home page I would get the following error

NoMethodError (undefined method `empty?' for nil:NilClass):
/app/controllers/wiki_controller.rb:47:in `edit'
/app/controllers/wiki_controller.rb:27:in `index'

Changing the following line (47 in wiki controller)

@content.text = "h1. #{@page.pretty_title}" if @content.text.empty?
to
@content.text = "h1. #{@page.pretty_title}" if @content.text.nil?

Appears to have fixed it for me, not sure what I have broken yet by doing this ;)

Actions #1

Updated by Thomas Lecavelier over 17 years ago

This patch correct the bug on my redmine for me too.

Actions #2

Updated by Jean-Philippe Lang over 17 years ago

Thanks, i've just fixed in trunk.
Used .blank? instead of .nil?

This was a regression due to the "mysql strict mode"
fix.

Sorry...

Actions

Also available in: Atom PDF