Skip to content

Commit

Permalink
Bug fix 🐛
Browse files Browse the repository at this point in the history
  • Loading branch information
NiiightmareXD committed Nov 14, 2024
1 parent ef1b4c0 commit 0ff824a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 22 deletions.
2 changes: 1 addition & 1 deletion windows-capture-python/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "1.4.1"
authors = ["NiiightmareXD"]
edition = "2021"
description = "Fastest Windows Screen Capture Library For Python 🔥"
readme = "README-Python.md"
readme = "README.md"
repository = "https://github.com/NiiightmareXD/windows-capture/tree/main/windows-capture-python"
license = "MIT"
keywords = ["screen", "capture", "screenshot", "graphics", "windows"]
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion windows-capture-python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ build-backend = "maturin"
name = "windows-capture"
version = "1.4.1"
description = "Fastest Windows Screen Capture Library For Python 🔥"
readme = "README-Python.md"
readme = "README.md"
requires-python = ">=3.9"
license = "MIT"
authors = [{ name = "NiiightmareXD" }]
Expand Down
22 changes: 2 additions & 20 deletions windows-capture-python/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -205,17 +205,8 @@ impl NativeWindowsCapture {
match InnerNativeWindowsCapture::start(settings) {
Ok(()) => (),
Err(e) => {
if let GraphicsCaptureApiError::FrameHandlerError(
InnerNativeWindowsCaptureError::PythonError(ref e),
) = e
{
return Err(PyException::new_err(format!(
"Capture Session Threw An Exception -> {e}",
)));
}

return Err(PyException::new_err(format!(
"Capture Session Threw An Exception -> {e}",
"InnerNativeWindowsCapture::start Threw An Exception -> {e}",
)));
}
}
Expand Down Expand Up @@ -243,17 +234,8 @@ impl NativeWindowsCapture {
match InnerNativeWindowsCapture::start(settings) {
Ok(()) => (),
Err(e) => {
if let GraphicsCaptureApiError::FrameHandlerError(
InnerNativeWindowsCaptureError::PythonError(ref e),
) = e
{
return Err(PyException::new_err(format!(
"Capture Session Threw An Exception -> {e}",
)));
}

return Err(PyException::new_err(format!(
"Capture Session Threw An Exception -> {e}",
"InnerNativeWindowsCapture::start Threw An Exception -> {e}",
)));
}
}
Expand Down

0 comments on commit 0ff824a

Please sign in to comment.