Showing 41 of 41 total issues
Function services
has 92 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const services = (state = initialServicesState, action) => {
switch (action.type) {
case ACTIONS.SET_SERVICES:
const newServices = action.services.slice(0)
newServices.forEach((service) => {
Function exports
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
module.exports = (mainWindow, manager) => {
const sendServices = () => {
console.log('Sending services list')
mainWindow.webContents.send('services', manager.services.map((service) => {
return {
Function NTLMXHRAPI
has 61 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const NTLMXHRAPI = (function () {
function ntlmXHRApi (user, password) {
this.userName = user
this.password = password
}
Function fetchAsana
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
fetchAsana ({now, tonight, friday}, api) {
if (api.token || api.refreshToken) {
let client
return (() => {
if (api.refreshToken) {
Function exports
has 58 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
module.exports = (mainWindow) => {
const authWindowOptions = {
alwaysOnTop: true,
autoHideMenuBar: true,
webPreferences: {
Function fetchTodoist
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
fetchTodoist ({now, tonight, friday}, api) {
if (api.token || api.refreshToken) {
const todoistRequest = (uri, params) => {
params.token = api.token
return request({
Widget
has 21 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class Widget extends Component {
constructor (title, name, props) {
super(props)
this.name = name
this.state = {
Function renderEditor
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderEditor () {
const tempConfig = this.getWidgetTempConfig()
if (tempConfig) {
return (
<div>
Consider simplifying this complex logical expression. Open
Open
if (this.props.services.services && this.props.services.services.length > 0) {
const cols = 3
return (
<div>
<ResponsiveReactGridLayout
Function buildMenu
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const buildMenu = (app, serviceManager) => {
const template = [
{
label: 'Application',
submenu: [
Function renderMailboxConfig
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderMailboxConfig (mailbox, i) {
switch (mailbox.type) {
case 'exchange':
return (
<div>
Function render
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render () {
if (this.props.services.services && this.props.services.services.length > 0) {
const cols = 3
return (
<div>
Function xhr
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ntlmXHRApi.prototype.xhr = function (xhroptions) {
const _this = this
let userName = _this.userName
let domain = ''
if (userName.indexOf('\\') >= 0) {
Function fetchImap
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
fetchImap (mailbox) {
const response = {
'unread': 0,
'flagged': 0
}
Function renderEditor
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderEditor () {
const tempConfig = this.getWidgetTempConfig()
const mailboxTypes = [
{
name: 'exchange',
Function renderEditor
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderEditor () {
const tempConfig = this.getWidgetTempConfig()
const apiTypes = [
{
name: 'asana',
Function renderEditor
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderEditor () {
const tempConfig = this.getWidgetTempConfig()
const calendarTypes = [
{
name: 'exchange',
Function exec
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
exec () {
if (this.config.location) {
const coords = zipcodes.lookup(this.config.location)
if (coords) {
return request({
Function fetchSingleFeed
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
fetchSingleFeed (feed) {
return new Promise((resolve, reject) => {
const items = []
const req = request({
'uri': feed,
Function exec
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
exec () {
if (this.config.credentials && this.config.credentials.access && this.config.credentials.access.token && this.config.credentials.access.tokenSecret) {
this.client = new TwitterClient({
'consumer_key': keys.twitter.key,
'consumer_secret': keys.twitter.secret,