MCPcopy Create free account
hub / github.com/decaporg/decap-cms / user

Method user

packages/decap-cms-backend-github/src/API.ts:281–290  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

279 static DEFAULT_COMMIT_MESSAGE = 'Automatically generated by Decap CMS';
280
281 user(): Promise<{ name: string; login: string; email?: string }> {
282 if (!this._userPromise) {
283 this._userPromise = this.getUser({ token: this.token });
284 }
285 return this._userPromise.then(user => ({
286 name: user.name || 'Unknown',
287 login: user.login,
288 email: user.email ?? undefined,
289 }));
290 }
291
292 async hasWriteAccess() {
293 try {

Callers 1

authenticateMethod · 0.45

Calls 1

getUserMethod · 0.95

Tested by

no test coverage detected