fix: Trim trailing digits from minimized classnames
This commit is contained in:
@@ -57,7 +57,7 @@ export default abstract class BaseStore<T extends BaseModel> {
|
|||||||
constructor(rootStore: RootStore, model: Class<T>) {
|
constructor(rootStore: RootStore, model: Class<T>) {
|
||||||
this.rootStore = rootStore;
|
this.rootStore = rootStore;
|
||||||
this.model = model;
|
this.model = model;
|
||||||
this.modelName = lowerFirst(model.name);
|
this.modelName = lowerFirst(model.name).replace(/\d$/, "");
|
||||||
|
|
||||||
if (!this.apiEndpoint) {
|
if (!this.apiEndpoint) {
|
||||||
this.apiEndpoint = `${this.modelName}s`;
|
this.apiEndpoint = `${this.modelName}s`;
|
||||||
|
|||||||
Reference in New Issue
Block a user