Permalink
Browse files

Merge branch 'wip-MDL-32106-MOODLE_22_STABLE' of git://github.com/mar…

…inaglancy/moodle into MOODLE_22_STABLE
  • Loading branch information...
2 parents da496c5 + e30281e commit 0161e20b651417312a68c4449dbcfe7a7e3e7fd4 @nebgor nebgor committed Mar 27, 2012
Showing with 3 additions and 3 deletions.
  1. +3 −3 repository/filepicker.js
View
@@ -657,13 +657,13 @@ M.core_filepicker.init = function(Y, options) {
params['author'] = author.get('value');
}
- if (this.options.env == 'editor') {
+ if (this.options.externallink && this.options.env == 'editor') {
// in editor, images are stored in '/' only
params.savepath = '/';
// when image or media button is clicked
if ( this.options.return_types != 1 ) {
- var linkexternal = Y.one('#linkexternal-'+client_id).get('checked');
- if (linkexternal) {
+ var linkexternal = Y.one('#linkexternal-'+client_id);
+ if (linkexternal && linkexternal.get('checked')) {
params['linkexternal'] = 'yes';
}
} else {

0 comments on commit 0161e20

Please sign in to comment.