MCPcopy Create free account
hub / github.com/codecombat/codecombat / signupWithPassword

Method signupWithPassword

app/models/User.js:1026–1037  ·  view source on GitHub ↗
(name, email, password, options = {})

Source from the content-addressed store, hash-verified

1024 }
1025
1026 signupWithPassword (name, email, password, options = {}) {
1027 options.url = _.result(this, 'url') + '/signup-with-password'
1028 options.type = 'POST'
1029 if (options.data == null) { options.data = {} }
1030 _.extend(options.data, { name, email, password })
1031 options.contentType = 'application/json'
1032 options.xhrFields = { withCredentials: true }
1033 options.data = JSON.stringify(options.data)
1034 const jqxhr = this.fetch(options)
1035 jqxhr.then(() => window.tracker?.trackEvent('Finished Signup', { category: 'Signup', label: 'CodeCombat' }))
1036 return jqxhr
1037 }
1038
1039 signupWithOauth2 (email, data = {}, options = {}) {
1040 options.url = _.result(this, 'url') + '/signup-with-oauth2'

Callers 6

onSubmitFormMethod · 0.80
createAccountFunction · 0.80
onTrialRequestSubmitMethod · 0.80
onSubmitFormMethod · 0.80
createAccountFunction · 0.80

Calls 3

stringifyMethod · 0.45
fetchMethod · 0.45
trackEventMethod · 0.45

Tested by

no test coverage detected