small fix

This commit is contained in:
Harry Bomrah 2016-03-25 01:33:29 +08:00
parent 09591e8ae5
commit 2dd19b2271
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ class Book
def self.get_plugin_datas_to_member(datas)
page = Page.where(:module => "personal_book").first rescue nil
if page.custom_string_field == "table"
if !page.nil? && page.custom_string_field == "table"
fields_to_show = [
"authors",
"book_title",