make it protected
161262
def update(other_hash)
      if other_hash.is_a? Hash
        super(other_hash)
      else
        other_hash.to_hash.each_pair do |key, value|
          if block_given?
            value = yield(key, value)
          end
          self[key] = value
        end
        self
      end
    end
915847
public function protect($column): void
	{
		foreach($this->items as $item)
		{
			$item->protect($column);
		}
	}
491285
public static String protect( JSON json, boolean shrink ) {
      String output = !shrink ? json.toString( 0 ) : toString( json );
      return webHijackPreventionStrategy.protect( output );
   }
338411
def guarded(self, call, *args):
        
        self.LOG.debug('%s(%s)' % (
            call.__name__, ', '.join([pretty_path(i) for i in args]),
        ))
        if not self.options.dry_run:
            try:
                call(*args)
            except (EnvironmentError, UnicodeError) as exc:
                self.fatal('%s(%s) failed [%s]' % (
                    call.__name__, ', '.join([pretty_path(i) for i in args]), exc,
                ))
423867
def secure(self):
        '''
            
        '''
        verbose('Saving information about target into conman database')
        self._id = self.db.insertTarget(self.name, self.path)

        verbose('Creating a hard link from {} to {} directory'.format(
            str(self), config.CONMAN_PATH   
        ))
        link(self.real_path, self.vault_path)
538440
private function protect()
    {
        if (!in_array($this->type, self::allAsString(), true)) {
            throw new \InvalidArgumentException(sprintf('Invalid token type "%s"', $this->type));
        }
    }
789005
def ensureVisible(self):
        
        parent = self.parent()
        while parent:
            parent.setExpanded(True)
            parent = parent.parent()
1243516
function ensureDir(dir, mode, callback) {
    var deferred = Q.defer();

    if (mode && typeof mode === 'function') {
        callback = mode;
        mode = null;
    }

    mode = mode || parseInt('0777', 8) & (~process.umask());


    _ensureDir(dir, mode, function (err) {
        if (err) {
            deferred.reject(err);
        } else {
            deferred.resolve();
        }
    });

    return deferred.promise.nodeify(callback);
}
200625
public function safeUp()
    {
        $auth = Yii::$app->authManager;

        // rules
        $ruleIsContentOwner = new IsContentOwnerRule;
        $auth->add($ruleIsContentOwner);
        
        // roles
        $roleContentModerator = $auth->createRole('roleContentModerator');
        $auth->add($roleContentModerator);

        $roleContentAuthor = $auth->createRole('roleContentAuthor');
        $auth->add($roleContentAuthor);

        $roleAdmin = $auth->getRole($this->roleAdmin);
        $auth->addChild($roleAdmin, $roleContentModerator); // system admin is moderator too

        $roleRoot = $auth->getRole($this->roleRoot);    // system developer - need all roles by default
        $auth->addChild($roleRoot, $roleContentAuthor); // root inherit roleContentModerator from admin

        // permissions
        $createContent = $auth->createPermission('createContent');
        $createContent->description = 'Create content';
        $auth->add($createContent);

        $deleteContent = $auth->createPermission('deleteContent');
        $deleteContent->description = 'Delete content';
        $auth->add($deleteContent);

        $updateContent = $auth->createPermission('updateContent');
        $updateContent->description = 'Update content';
        $auth->add($updateContent);

        $updateOwnContent = $auth->createPermission('updateOwnContent');
        $updateOwnContent->description = 'Update own content';
        $updateOwnContent->ruleName = $ruleIsContentOwner->name;
        $auth->add($updateOwnContent);

        $auth->addChild($updateOwnContent, $updateContent); //??

        // permissions in roles
        $auth->addChild($roleContentAuthor, $createContent);
        $auth->addChild($roleContentAuthor, $updateOwnContent);
        $auth->addChild($roleContentModerator, $updateContent);
        $auth->addChild($roleContentModerator, $deleteContent);
    }
1127746
def _consolidate_inplace(self):
        """"""

        def f():
            self._data = self._data.consolidate()

        self._protect_consolidate(f)
897433
function ensureDir(dir) {
  return new Promise((resolve, reject) => {
    try {
      FS.ensureDirSync(dir);
      resolve(dir);
    } catch (err) {
      reject(err);
    }
  });
}
242160
public void makePrivate() {
        if (getPublicMarkerFile().exists()) {
            if (getPublicMarkerFile().delete()) {
                publicAccessCache.put(getName(), false);
            } else {
                Storage.LOG.WARN("Failed to delete public marker for bucket %s - it remains public!", getName());
            }
        }
    }
1161203
def enable_encryption(self, output_key, input_key):
        """"""
        self._chacha = chacha20.Chacha20Cipher(output_key, input_key)
1097625
def cover(self):
        
        if not self._cover:
            self._cover = Picture(self._cover_url, self._connection)
        return self._cover
972728
def protected_view(view, info):
    """"""

    if info.options.get('protected'):
        def wrapper_view(context, request):
            response = _advice(request)
            if response is not None:
                return response
            else:
                return view(context, request)
        return wrapper_view
    return view
143713
def allow(self, ip):
        
        self.whitelist.append(ip)
        self.blacklist.clear()
65770
private static function secure() {
	if (\alsvanzelf\fem\CLI) {
		return;
	}
	
	header_remove('X-Powered-By');
	
	ini_set('session.use_trans_sid',    0);
	ini_set('session.use_only_cookies', 1);
	ini_set('session.cookie_httponly',  1);
	ini_set('session.use_strict_mode',  1); // @note this is only effective from 5.5.2
	ini_set('session.entropy_file',     '/dev/urandom');
}