ZaraclaJ / audio_recorder

Other
180 stars 127 forks source link

Error: A constructor invocation can't have type arguments on the constructor name. #28

Closed apurvh closed 5 years ago

apurvh commented 6 years ago

I am getting following error after including the plugin

Compiler message: file:///Users/apurv2017/dev/flutter/.pub-cache/hosted/pub.dartlang.org/audio_recorder-0.0.6/lib/audio_recorder.dart:49:13: Error: A constructor invocation can't have type arguments on the constructor name. Try to place the type arguments on the class name. Map.from<String, Object>(await _channel.invokeMethod('stop')); ^^^^ Compiler failed on /Users/apurv2017/AndroidStudioProjects/app_name/lib/main.dart Finished with error: Gradle task assembleDebug failed with exit code 1

flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel beta, v0.10.2, on Mac OS X 10.13.6 17G65, locale en-IN) [✓] Android toolchain - develop for Android devices (Android SDK 28.0.2) [✓] iOS toolchain - develop for iOS devices (Xcode 10.0) [✓] Android Studio (version 3.2) [!] VS Code (version 1.28.2) [✓] Connected device (1 available)

apurvh commented 6 years ago

@ZaraclaJ can you please check/accept the pull request as soon as possible?

awazgyawali commented 5 years ago

Waiting this issue to be resolved.

apurvh commented 5 years ago

I refactored and fixed bugs in audio_recorder2 if you need the fixes urgently can try this

awazgyawali commented 5 years ago

Whereas I referenced the PR https://github.com/ZaraclaJ/audio_recorder/pull/27 sent by @mmcc007 to fix the issue.

In pubspec.yaml audio_recorder: git: url: git@github.com:ZaraclaJ/audio_recorder.git ref: 7957e5a

Pashokresh commented 5 years ago

Whereas I referenced the PR #27 sent by @mmcc007 to fix the issue.

In pubspec.yaml audio_recorder: git: url: git@github.com:ZaraclaJ/audio_recorder.git ref: 7957e5a

I get an error: Running "flutter packages get" in vpbx-mobile... Git error. Command: git rev-list --max-count=1 7957e5a fatal: ambiguous argument '7957e5a': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git [...] -- [...]'

mmcc007 commented 5 years ago

@Pashokresh Not sure what the problem is, but there is a forked version of this plugin from @Apurv2017 that, I think, does not have this problem: https://github.com/Apurv2017/audioRecorder2