Changeset 2124
- Timestamp:
- 11/25/2009 12:34:55 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/1.1/bp-core/bp-core-avatars.php
r2118 r2124 222 222 223 223 $uploadErrors = array( 224 225 226 227 228 229 224 0 => __("There is no error, the file uploaded with success", 'buddypress'), 225 1 => __("Your image was bigger than the maximum allowed file size of: ", 'buddypress') . size_format(BP_AVATAR_ORIGINAL_MAX_FILESIZE), 226 2 => __("Your image was bigger than the maximum allowed file size of: ", 'buddypress') . size_format(BP_AVATAR_ORIGINAL_MAX_FILESIZE), 227 3 => __("The uploaded file was only partially uploaded", 'buddypress'), 228 4 => __("No file was uploaded", 'buddypress'), 229 6 => __("Missing a temporary folder", 'buddypress') 230 230 ); 231 231 … … 269 269 $bp->avatar_admin->image->dir = $bp->avatar_admin->resized; 270 270 @unlink( $bp->avatar_admin->original['file'] ); 271 } 272 273 /* Check for WP_Error on what should be an image */ 274 if ( is_wp_error( $bp->avatar_admin->image->dir ) ) { 275 bp_core_add_message( sprintf( __( 'Upload failed! Error was: %s', 'buddypress' ), $bp->avatar_admin->image->dir->get_error_message() ), 'error' ); 276 return false; 271 277 } 272 278
Note: See TracChangeset
for help on using the changeset viewer.