Ember:SimpleAuth is undefined using ember-simple-auth - ember-simple-auth

I am a newbie to JaveScript and HTML.
Looking at an existing code and struggling with below from quite some time now.
Below is the console output.
Getting the Uncaught error at below line in my code.
App.CustomAuthenticator = Ember.SimpleAuth.Authenticators.Base.extend({
The Ember.SimpleAuth is showing as undefined.
DEBUG: ------------------------------- ember.js:3461
DEBUG: Ember : 1.4.0 ember.js:3461
DEBUG: Ember Data : 1.0.0-beta.7+canary.b45e23ba ember.js:3461
DEBUG: Handlebars : 1.1.2 ember.js:3461
DEBUG: jQuery : 1.9.1 ember.js:3461
DEBUG: Ember Simple Auth : 0.6.4 ember.js:3461
DEBUG: ------------------------------- ember.js:3461
Uncaught TypeError: Cannot read property 'Authenticators' of undefined
Appreciate the help

Ember Simple Auth now defines its own global SimpleAuth and doesn't attach to the Ember global anymore so you need to change your code to:
App.CustomAuthenticator = SimpleAuth.Authenticators.Base.extend({
…
})

Related

Node js Deploiement Plesk Error: age/Spa/SpawnEnvSetupperMain.cpp:747 ]: shellName = 'false' detected as supporting '-l': false

I have this error when i deploy my node js application in plesk Server
I don't understund this problem:
"age/Spa/SpawnEnvSetupperMain.cpp:747 ]: shellName = 'false' detected as supporting '-l': false"
someone can help me please Image

How do I install swagger in a Sails.js 1.x no-frontend project?

I recently started a new sail.js 1.2.3 project for building apis. I installed the project with the --no-frontend option specified.
I have the following npm packages installed:
"sails-hook-orm": "^2.1.1",
"sails-hook-sockets": "^2.0.0",
"sails-hook-swagger-generator": "^2.8.2",
"sails-postgresql": "^1.0.2",
"sails-swagger": "^0.5.1",
"sails-util-micro-apps": "^1.1.1",
"swagger-ui-dist": "^3.23.11",
I created a swagger folder in my project, and when I run sails lift , the swagger.json file gets rebuilt (I think correctly).
However, I cannot get swagger-ui configured to use the swagger.json file, and I can't get the sails.js project to display the swagger-ui docs.
Here's what I already tried:
Swagger Sails JS
Here's the results from running sails lift:
debug: hookPath: C:\Users\...\node_modules\sails-swagger\dist\api\hooks\swagger
debug: marlinspike (swagger): loading config from C:\Users\...\node_modules\sails-swagger\dist\config
debug: In route `/swagger/doc`:
debug: The `cors.origin` config has been deprecated.
debug: Please use `cors.allowOrigins` instead.
debug: (See http://sailsjs.com/config/security for more info.)
debug: In route `/swagger/doc`:
debug: The `cors.methods` config has been deprecated.
debug: Please use `cors.allowRequestMethods` instead.
debug: In route `/swagger/doc`:
debug: When specifying multiple allowable CORS origins, the allowOrigins setting
debug: should be an array of strings. We'll split it up for you this time...
debug: marlinspike (swagger): loading Services from C:\Users\...\node_modules\sails-swagger\dist\api\services...
warn: marlinspike (swagger): no Services found. skipping
debug: marlinspike (swagger): loading Models...
debug: marlinspike (swagger): loading Controllers...
debug: marlinspike (swagger): loading Policies...
warn: marlinspike (swagger): no Policies found. skipping
No tag for this identity 'status'
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity ''
No tag for this identity 'swagger'
No tag for this identity 'swagger'
No tag for this identity 'swagger'
No tag for this identity 'swagger'
No tag for this identity 'swagger'
No tag for this identity 'swagger'
info: ·• Auto-migrating... (drop)
Swagger generated successfully
info: ✓ Auto-migration complete.
warn: Ignored attempt to bind route (/swagger/doc) to unknown action :: { cors:
{ allowOrigins: [ 'http://swagger.balderdash.io' ],
allowRequestMethods: 'GET,OPTIONS,HEAD',
allRoutes: true,
allowCredentials: true,
allowRequestHeaders: 'content-type',
allowResponseHeaders: '',
allowAnyOriginWithCredentialsUnsafe: false },
controller: 'SwaggerController',
action: 'doc' }
info:
info: .-..-.
info:
info: Sails <| .-..-.
info: v1.2.3 |\
info: /|.\
info: / || \
info: ,' |' \
info: .-'.-==|/_--'
info: `--'-------'
info: __---___--___---___--___---___--___
info: ____---___--___---___--___---___--___-__
info:
info: Server lifted in `C:\Users\...`
info: To shut down Sails, press <CTRL> + C at any time.
info: Read more at https://sailsjs.com/support.
I want to run sails lift, have the swagger.json file updated, then have a route/path I can use to see the expected swagger ui.
Thanks in advance!```

TypeError: Cannot read property 'XXX' of null

Puppeteer version: 1.0.0
OS version: Mac OS
Node.js version: 8.9.1
Error log:
TypeError: Cannot read property 'innerText' of null
here is my code
I am in trouble.Can anyone helps me?

Cannot run Angular app from browser

I got the following error messages when accessing my app from the browser with :
54.255.239.55:3443/home/app/index.html
GET https://54.255.239.55:3443/home/bower_components/angular/angular.min.js net::ERR_CONNECTION_RESET
GET https://54.255.239.55:3443/home/bower_components/angular-ui-router/release/angular-ui-router.min.js net::ERR_CONNECTION_RESET
GET https://54.255.239.55:3443/home/bower_components/font-awesome/css/font-awesome.min.css net::ERR_CONNECTION_RESET
GET https://54.255.239.55:3443/home/app/styles/bootstrap-social.css net::ERR_CONNECTION_RESET
GET https://54.255.239.55:3443/home/bower_components/bootstrap/dist/css/bootstrap-them.min.css net::ERR_CONNECTION_RESET
Uncaught TypeError: Cannot read property '$$minErr' of undefined
at angular-resource.min.js:6
at angular-resource.min.js:14
Uncaught TypeError: Cannot read property 'module' of undefined
at angular-resource.min.js:6
at angular-resource.min.js:14
Uncaught TypeError: Cannot read property 'module' of undefined
at ngDialog.min.js:2
at ngDialog.min.js:2
at ngDialog.min.js:2
Uncaught ReferenceError: angular is not defined
at app.js:3
Uncaught ReferenceError: angular is not defined
at controllers.js:3
Uncaught ReferenceError: angular is not defined
at services.js:3
My project file structure is:
app
-images
-scripts
-styles
-views
bower_components
-css
-bootstrap.css
-bootstrap.css.map
-bootstrap.min.css
-bootstrap.min.css.map
-bootstrap-theme.css
-bootstrap-theme.css.map
-bootstrap-theme.min.css
-bootstrap-theme.min.css.map
-fonts
-js
-bootstrap.js
-bootstrap.min.js
-npm.js
-node_modules
I need help please.

Can't find variable: loadFixtures

I am using karma, jasmine and phantomjs for my project and when I am executing start karma; I am getting following error:
PhantomJS 1.9.7 (Linux) View:: Login guestRegistration Should call the guestRegistration event when btn-grey is clicked FAILED
ReferenceError: Can't find variable: loadFixtures
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:84
ReferenceError: Can't find variable: spyOnEvent
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:89
PhantomJS 1.9.7 (Linux) View:: Login Check for blur event Should call the checkElementToValidate event when username is blurred FAILED
ReferenceError: Can't find variable: readFixtures
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:103
ReferenceError: Can't find variable: spyOnEvent
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:112
PhantomJS 1.9.7 (Linux) View:: Login Check for blur event Should call the checkElementToValidate event when username is blurred FAILED
ReferenceError: Can't find variable: readFixtures
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:103
ReferenceError: Can't find variable: spyOnEvent
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:123
PhantomJS 1.9.7 (Linux) View:: Login Check for blur event Should call the addLoginInputPlaceholder event when login-input is blurred FAILED
ReferenceError: Can't find variable: readFixtures
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:103
ReferenceError: Can't find variable: spyOnEvent
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:133
PhantomJS 1.9.7 (Linux) View:: Login Check for focus event Should call the addLoginInputPlaceholder event when login-input is focussed FAILED
ReferenceError: Can't find variable: readFixtures
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:146
ReferenceError: Can't find variable: spyOnEvent
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:154
PhantomJS 1.9.7 (Linux) View:: Login Check whether sendFormdata() triggers submit form Should trigger the submit:form method atleast once FAILED
ReferenceError: Can't find variable: sinon
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/test/javascript/spec/login.view.spec.js:231
PhantomJS 1.9.7 (Linux) ERROR
SyntaxError: Unable to parse JSON string
at /apps/devops/jenkins/home/jobs/UIMod-Jasmine-Karma/workspace/WebContent/js/controllers/common/base.controller.js:107
PhantomJS 1.9.7 (Linux): Executed 21 of 38 (6 FAILED) ERROR (2.36 secs / 1.854 secs)
The error is can't find variable loadFixture. Can anyone tell me what is the reason behind this error?
It seems like you're using jasmine-jquery. First make sure you install it with npm. Can you also make sure that your karma.conf.js has a similar entry:
frameworks: ['jasmine-jquery', 'jasmine']
The order of the frameworks matters.

Resources