You've already forked matrix-react-sdk
							
							
				mirror of
				https://github.com/matrix-org/matrix-react-sdk.git
				synced 2025-11-04 11:51:45 +03:00 
			
		
		
		
	Sentry uses RELEASE from webpack to correspond with sourcemap uploader (#6996)
use RELEASE from webpack to correspond with sourcemap uploader
This commit is contained in:
		@@ -15,7 +15,6 @@ limitations under the License.
 | 
			
		||||
*/
 | 
			
		||||
 | 
			
		||||
import * as Sentry from "@sentry/browser";
 | 
			
		||||
import PlatformPeg from "./PlatformPeg";
 | 
			
		||||
import SdkConfig from "./SdkConfig";
 | 
			
		||||
import { MatrixClientPeg } from "./MatrixClientPeg";
 | 
			
		||||
import SettingsStore from "./settings/SettingsStore";
 | 
			
		||||
@@ -200,15 +199,9 @@ interface ISentryConfig {
 | 
			
		||||
 | 
			
		||||
export async function initSentry(sentryConfig: ISentryConfig): Promise<void> {
 | 
			
		||||
    if (!sentryConfig) return;
 | 
			
		||||
    const platform = PlatformPeg.get();
 | 
			
		||||
    let appVersion = "unknown";
 | 
			
		||||
    try {
 | 
			
		||||
        appVersion = await platform.getAppVersion();
 | 
			
		||||
    } catch (e) {}
 | 
			
		||||
 | 
			
		||||
    Sentry.init({
 | 
			
		||||
        dsn: sentryConfig.dsn,
 | 
			
		||||
        release: `${platform.getHumanReadableName()}@${appVersion}`,
 | 
			
		||||
        release: process.env.RELEASE,
 | 
			
		||||
        environment: sentryConfig.environment,
 | 
			
		||||
        defaultIntegrations: false,
 | 
			
		||||
        autoSessionTracking: false,
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user