Mistři v programování na #hovnokod

I get: Error. ReferenceError: `bot` is not defined

  const isAdmin = (chat, user) => {
    var status = bot.telegram.getChatMember(chat, user);
    return status.then(function(result) {
      if (result.status == "creator" || result.status == "administrator") {
        return true;
      } else {
        return false;
      }
    });
  }

  module.exports = {
    isAdmin
  };

Anonymous,

fíjó!

		// Shift keys
		if ($this.hasClass('left-shift') || $this.hasClass('right-shift')) {
			$('.letter').toggleClass('uppercase');
			$('.symbol span').toggle();

			shift = (shift === true) ? false : true;
			capslock = false;
			return false;
		}
		}

		// Remove shift once a key is clicked.
		if (shift === true) {
			$('.symbol span').toggle();
			if (capslock === false)
				$('.letter').toggleClass('uppercase');

			shift = false;
		}

		// Add the character
		$passwordField.val($passwordField.val() + character);
		$passwordField.trigger("change");

Anonymous,

Obfuskacia kodu uz pri pisani. Nikto nema paru co je prepojene s cim, kde a odkial to ide, samozrejme je takto pisany cely projekt. Pozdravujem nemenovanu slovensku firmu ktoru nedavno odkupila nemenovana ceska firma... ktora vyvyja nemenovany antivirusovi softver....

this.modelsRouterRoutesOptions.post.errorController = this.postErrorController.bind(this);

Anonymous,

Kolegové "vývojáři" z Indie... A takhle je psaný celý projekt. Špagety kam se podíváš, divím se, že to vůbec funguje ...

if(formdata.attachType.toUpperCase()=='BROWSE'){
                                //Change the Post API Url if upload file extension is Zip while creating the Resource
                                if(formdata.resource && formdata.resource.name) {
                                var fileExt1 = formdata.resource.name.split('.')[formdata.resource.name.split('.').length -1];
                                if(fileExt1.toUpperCase() == 'ZIP' && (formdata.type.toUpperCase()=='R' || formdata.type.toUpperCase()=='PYTHON')){
                                    createResourceUrl = 'admin/res/createForZip';
                                    }
                                }
                                    // Change the post API url if file extension is zip while CLONING a resource
                                if(formdata.resource && formdata.resource.resourceName) {
                                    var fileExt2 = formdata.resource.resourceName.split('.')[formdata.resource.resourceName.split('.').length -1];
                                    if(fileExt2.toUpperCase() == 'ZIP' && (formdata.type.toUpperCase()=='R' || formdata.type.toUpperCase()=='PYTHON')){
                                    createResourceUrl = 'admin/res/createForZip';
                                    }
                                }
                            }

Anonymous,

a dalo se to napsat zloziteji?

(actions.includes("EDIT_ACTION") || actions.includes("SHOW_ACTION") || actions.includes('CREATE_ACTION')) ? this.showComponent = true : '';
(actions.includes("EDIT_ACTION") || actions.includes('CREATE_ACTION')) ? this.showButtonSave = true : '';
actions.includes("SAVE_ACTION") ? this.allowSave = true : '';

if(actions.includes("EDIT_ACTION") || actions.includes("SHOW_ACTION") || actions.includes('CREATE_ACTION') || actions.includes("SAVE_ACTION")) {
	this.showTab = true;
} else {
	this.showTab = false;
}

Anonymous,