emmar
committed
on 31 Mar 09
Added logic to send out the notification in the user language if set, fallback to system one, in case the notification content is i18n'd.
openacs-4/.../shared/portrait-bits.tcl (+3 -5)
6 6     @cvs-id $Id$
7 7 } {
8 8     user_id:integer
9 9     {item_id ""}
10 10     {size ""}
11 11 }
12 12
13 13
14 14 # If the item_id is provided then we are fine
15 15 if {$item_id eq ""} {
16 16     if { ![db_0or1row get_item_id ""] } {
17 17         #    ad_return_error "Couldn't find portrait" "Couldn't find a portrait for User $user_id"
18 18         ad_return_string_as_file -string "" -mime_type "image/jpeg" -filename ""
19 19         return
20 20     }
21 21 }   
22 22
23 23 if { $size eq "" } {
24 24     cr_write_content -item_id $item_id
25 25 } else {        
26       ad_returnredirect "/image/${item_id}/thumbnail"
27      
  26     ad_returnredirect "/image/${item_id}/${size}"
28 27 }
29