Skip to content

Commit

Permalink
fix: deprecated syntax of lower substr (#3013)
Browse files Browse the repository at this point in the history
* fixed import error syntax

* replace lower.substr with lower.substring

* remove redundant parameter

* fixed import syntax error

* fixed import syntax error
  • Loading branch information
wx0322 authored Nov 10, 2022
1 parent 173b656 commit 08c58b0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion platform/core/src/extensions/ExtensionManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -365,5 +365,5 @@ export default class ExtensionManager {
* @param {string} lower
*/
function _capitalizeFirstCharacter(lower) {
return lower.charAt(0).toUpperCase() + lower.substr(1);
return lower.charAt(0).toUpperCase() + lower.substring(1);
}
5 changes: 2 additions & 3 deletions platform/viewer/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import PropTypes from 'prop-types';
import i18n from '@ohif/i18n';
import { I18nextProvider } from 'react-i18next';
import { BrowserRouter } from 'react-router-dom';
import Compose from './routes/Mode/Compose.tsx';
import Compose from './routes/Mode/Compose';

import {
DialogProvider,
Expand All @@ -22,7 +22,7 @@ import {
import { AppConfigProvider } from '@state';
import createRoutes from './routes';
import appInit from './appInit.js';
import OpenIdConnectRoutes from './utils/OpenIdConnectRoutes.tsx';
import OpenIdConnectRoutes from './utils/OpenIdConnectRoutes';

let commandsManager, extensionManager, servicesManager, hotkeysManager;

Expand Down Expand Up @@ -60,7 +60,6 @@ function App({ config, defaultExtensions, defaultModes }) {
servicesManager,
commandsManager,
hotkeysManager,
commandsManager,
routerBasename,
});
const {
Expand Down
2 changes: 1 addition & 1 deletion platform/viewer/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Entry point for development and production PWA builds.
*/
import 'regenerator-runtime/runtime';
import App from './App.tsx';
import App from './App';
import React from 'react';
import ReactDOM from 'react-dom';

Expand Down

0 comments on commit 08c58b0

Please sign in to comment.