Showing 3,235 of 4,504 total issues
Storage
has 21 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class Storage implements IStorage {
// hidden file which indicate that the folder is a valid key storage
public const KEY_STORAGE_MARKER = '.oc_key_storage';
/** @var View */
OC_Defaults
has 21 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class OC_Defaults {
private $theme;
private $l;
private $defaultEntity;
Function move
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
move: function(fileNames, targetPath) {
var self = this;
var dir = this.getCurrentDirectory();
if (dir.charAt(dir.length - 1) !== '/') {
dir += '/';
Function _handleUpdateShareAttributes
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_handleUpdateShareAttributes: function(shareId, properties, options) {
var shareAttributesV1 = [];
var filteredAttributes = [];
var filteredRegisteredAttributes = this._filterRegisteredAttributes(properties.permissions);
_.map(filteredRegisteredAttributes, function(filteredRegisteredAttribute) {
Function resampleHermite
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var resampleHermite = function (canvas, W, H, W2, H2) {
W2 = Math.round(W2);
H2 = Math.round(H2);
var img = canvas.getContext("2d").getImageData(0, 0, W, H);
var img2 = canvas.getContext("2d").getImageData(0, 0, W2, H2);
Method formatUserForIndex
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function formatUserForIndex(IUser $user, array $userGroups = null) {
// TODO: eliminate this encryption specific code below and somehow
// hook in additional user info from other apps
// recovery isn't possible if admin or user has it disabled and encryption
Method listApps
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function listApps($category = '') {
if ($category === '') {
$category = 'enabled';
}
switch ($category) {
Method run
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function run($argument) {
$target = $argument['url'];
$source = $this->urlGenerator->getAbsoluteURL('/');
$source = \rtrim($source, '/');
$token = $argument['token'];
Method auth
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function auth(RequestInterface $request, ResponseInterface $response) {
$forcedLogout = false;
if (!$this->request->passesCSRFCheck() &&
$this->requiresCSRFCheck()) {
// In case of a fail with POST we need to recheck the credentials
Method checkAppsIntegrity
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function checkAppsIntegrity($data, $extractDir, $path, $isShipped = false) {
$l = \OC::$server->getL10N('lib');
//load the info.xml file of the app
if (!\is_file($extractDir.'/appinfo/info.xml')) {
//try to find it in a subdir
Method sendEmail
has 54 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function sendEmail($user, $token, $link) {
if ($this->userManager->userExists($user)) {
$userObject = $this->userManager->get($user);
$email = $userObject->getEMailAddress();
Method wrap
has 17 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
$source,
$internalPath,
$fullPath,
array $header,
$uid,
File et_EE.js
has 255 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
OC.L10N.register(
"settings",
{
"Wrong current password" : "Vale praegune parool",
"No user supplied" : "Kasutajat ei sisestatud",
Function display
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
display: function (parent, triggerEvent, fileList) {
if (!fileList) {
console.warn('FileActions.display() MUST be called with a OCA.Files.FileList instance');
return;
}
Function _extendFileList
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_extendFileList: function(fileList) {
// extend row prototype
fileList.$el.addClass('has-favorites');
var oldCreateRow = fileList._createRow;
fileList._createRow = function(fileData) {
Function render
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function() {
var self = this;
// render shares list in a container
this.$el.html(this.template({
Function addConflict
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var addConflict = function($conflicts, original, replacement) {
var $conflict = $conflicts.find('.template').clone().removeClass('template').addClass('conflict');
var $originalDiv = $conflict.find('.original');
var $replacementDiv = $conflict.find('.replacement');
Method getAssignableAndRemovableGroups
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function getAssignableAndRemovableGroups() {
$assignableGroups = [];
$removableGroups = [];
$currentUser = $this->userSession->getUser();
Method getTrashFiles
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function getTrashFiles($dir, $user, $sortAttribute = '', $sortDescending = false, $addExtraData = true) {
$result = [];
$timestamp = null;
$view = new \OC\Files\View('/' . $user . '/files_trashbin/files');
Method restore
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function restore($filename, $targetLocation = null) {
$user = User::getUser();
$view = new View('/' . $user);
$nameOfFile = \basename($filename);
$dirOfFile = \dirname($filename);