razorpay / razorpay-flutter

Razorpay Flutter Plugin
MIT License
106 stars 149 forks source link

[FEATURE] `_rpay.open()` as a Future<void> event #291

Open opxdelwin opened 1 year ago

opxdelwin commented 1 year ago

Please provide all the information requested. Issues that do not follow this format are likely to stall.

Description

Please provide a clear and concise description of what the bug is. Include screenshots if needed. Please test using the latest Razorpay Flutter plugin release to make sure your issue has not already been fixed:

Flutter Version :

Flutter 3.3.10 • channel stable • https://github.com/flutter/flutter.git Framework • revision 135454af32 (4 weeks ago) • 2022-12-15 07:36:55 -0800 Engine • revision 3316dd8728 Tools • Dart 2.18.6 • DevTools 2.15.0

Expected Results

Use await keyword with _rpay.open() to execute other functions such as checking backend for payment confirmation once transaction is complete.

Eg: • User makes payment -> Payment interface is closed. • now If I've to run a function to check transaction status, I've to wait for _rpay to close, hence make .open() function Future<void> from void