Getting rid of userInstanceMap, preparing for meat of auth update.
This commit is contained in:
parent
adac862ccd
commit
d9025d1aa1
|
@ -70,7 +70,6 @@ exports.create = async function(ctx) {
|
||||||
const newApplication = {
|
const newApplication = {
|
||||||
_id: appId,
|
_id: appId,
|
||||||
type: "app",
|
type: "app",
|
||||||
userInstanceMap: {},
|
|
||||||
version: packageJson.version,
|
version: packageJson.version,
|
||||||
componentLibraries: ["@budibase/standard-components"],
|
componentLibraries: ["@budibase/standard-components"],
|
||||||
name: ctx.request.body.name,
|
name: ctx.request.body.name,
|
||||||
|
|
|
@ -39,13 +39,6 @@ exports.create = async function(ctx) {
|
||||||
|
|
||||||
const response = await db.post(user)
|
const response = await db.post(user)
|
||||||
|
|
||||||
const app = await db.get(ctx.user.appId)
|
|
||||||
app.userInstanceMap = {
|
|
||||||
...app.userInstanceMap,
|
|
||||||
[username]: ctx.user.appId,
|
|
||||||
}
|
|
||||||
await db.put(app)
|
|
||||||
|
|
||||||
ctx.status = 200
|
ctx.status = 200
|
||||||
ctx.message = "User created successfully."
|
ctx.message = "User created successfully."
|
||||||
ctx.userId = response._id
|
ctx.userId = response._id
|
||||||
|
|
Loading…
Reference in New Issue