We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 21c3cb6 commit f36352bCopy full SHA for f36352b
src/v2/service/texture.service.ts
@@ -129,9 +129,11 @@ export default class TextureService {
129
return createdTexture;
130
}
131
132
- createEntireTextures(body: EntireTextureToCreate[]): Promise<Textures> {
133
- // create textures
134
- return Promise.all(body.map((t) => this.createEntireTexture(t)));
+ async createEntireTextures(body: EntireTextureToCreate[]): Promise<Textures> {
+ const res: Textures = [];
+ // must be done synchronously to prevent id collisions
135
+ for (const tex of body) res.push(await this.createEntireTexture(tex));
136
+ return res;
137
138
139
async changeTexture(id: string, body: TextureCreationParam): Promise<Texture> {
0 commit comments