Skip to content

Commit

Permalink
Move platforms to core lib
Browse files Browse the repository at this point in the history
  • Loading branch information
ljoonal committed Apr 16, 2023
1 parent 6e707a6 commit 343d951
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
6 changes: 5 additions & 1 deletion onlivfe/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#![allow(clippy::multiple_crate_versions)]

use serde::{Deserialize, Serialize};
use strum::{AsRefStr, EnumCount, EnumIter};
use strum::{AsRefStr, EnumCount, EnumIter, IntoEnumIterator};
use time::OffsetDateTime;

pub mod cvr;
Expand Down Expand Up @@ -56,6 +56,10 @@ pub enum PlatformType {
NeosVR,
}

/// Gets all the platforms
#[must_use]
pub fn platforms() -> Vec<PlatformType> { PlatformType::iter().collect() }

macro_rules! platform_specific {
($name:ident) => {
impl From<&$name> for crate::PlatformType {
Expand Down
7 changes: 0 additions & 7 deletions onlivfe_wrapper/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,6 @@ impl<StorageBackend: onlivfe::storage::OnlivfeStore> Onlivfe<StorageBackend> {
})
}

/// Gets all the different platforms, useful for syncing unrelated codebases
/// to the core's capabilities
#[instrument]
pub async fn platforms(&self) -> Vec<PlatformType> {
PlatformType::iter().collect()
}

/// Gets currently authenticated API user IDs.
///
/// # Errors
Expand Down

0 comments on commit 343d951

Please sign in to comment.