Index: openacs-4/packages/general-comments/tcl/general-comments-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/general-comments/tcl/general-comments-procs.tcl,v diff -u -r1.20 -r1.21 --- openacs-4/packages/general-comments/tcl/general-comments-procs.tcl 5 May 2007 15:54:47 -0000 1.20 +++ openacs-4/packages/general-comments/tcl/general-comments-procs.tcl 27 Oct 2014 16:41:42 -0000 1.21 @@ -48,7 +48,7 @@ # created comment. This is done here to ensure that # a fail on permissions granting will not leave # the comment with incorrect permissions. - if {![empty_string_p $user_id]} { + if {$user_id ne ""} { permission::grant -object_id $comment_id \ -party_id $user_id \ -privilege "read" @@ -96,7 +96,7 @@ # get the package url set package_url [general_comments_package_url] - if { [empty_string_p $package_url] } { + if { $package_url eq "" } { return "" } @@ -138,7 +138,7 @@ set content_select [db_map content_select] ;# ", r.content" } - if { ![empty_string_p $context_id] } { + if { $context_id ne "" } { set context_clause "and o.context_id = :context_id" } else { set context_clause "" @@ -209,7 +209,7 @@ and r.revision_id = i.live_revision" { append attachments_html "
  • $title " - if { $mime_type == "image_gif" || $mime_type == "image/jpeg" } { + if { $mime_type eq "image_gif" || $mime_type eq "image/jpeg" } { append attachments_html "($name)\n" } else { append attachments_html "($name)\n" @@ -222,13 +222,13 @@ where i.parent_id = :comment_id and e.extlink_id = i.item_id" { append attachments_html "
  • $label\n" } - if { ![empty_string_p $attachments_html] } { + if { $attachments_html ne "" } { append html "
    [_ general-comments.Attachments]
    \n\n" } } - append html "

    -- $author [_ general-comments.on] $pretty_date2 ([_ general-comments.view_details])

    \n" + append html "

    -- $author [_ general-comments.on] $pretty_date2 ([_ general-comments.view_details])

    \n" } else { - append html "
  • $title" + append html "
  • $title" if {$print_user_info_p} { append html " [_ general-comments.by] $author [_ general-comments.on] $pretty_date
    \n" } else { @@ -263,15 +263,15 @@ } { # get the package url set package_url [general_comments_package_url] - if { [empty_string_p $package_url] } { + if { $package_url eq "" } { return "" } # initialize variables if { ![info exists object_name] } { set object_name [acs_object_name $object_id] } if { ![info exists context_id] } { set context_id $object_id } - set html "$link_text" + set html "$link_text" return $html } @@ -318,7 +318,7 @@ o.object_id = g.comment_id and p.person_id = o.creation_user order by creation_date" { - append html "
  • $title by $author, $creation_date
    \n" + append html "
  • $title by $author, $creation_date
    \n" } return "$html" } @@ -336,7 +336,7 @@ # get the package url set package_url [general_comments_package_url] - set html "$link_text" + set html "$link_text" return $html }